When docker starts tomcat, the access port of the container displays 404, and the source server fails to find the representation of the target resource or is unwilling to disclose an existing one

Solution:
systemctl stop firewalld.
systemctl disable firewalld.
s>mctl disable firewalld.
systemctl disable firewalld.
systemctl disable firewalld.
systemctl disable firewalld.
systemctl disable firewalld.
systemctl disable firewalld If Tomcat is still inaccessible after the firewall is turned off, the webapps folder is empty
2. The problem of webapps folder is empty check the tomcat container ID

docker ps
enter tomcat container terminal
docker exec – it tomcat container ID/bin/bash
enter
CD webapps webapps folder
copy on a webapps directory. All files to the webapps directory under the dist
cp – r.. /webapps.dist/* ./

Read More: