Open the Docker Desktop.
Change the current path to the location of orange-frontstage-api project.
Use Dockerfile build tomcat env image.
docker image build -f Dockerfile -t orange-tomcat:1.0 .
Check image as this command.
docker image ls -a
Run container use image.
docker container run --name orange-frontstage-service -itd --rm -p 8080:8080 orange-tomcat:1.0
Check logs with container, it show tomcat logs.
docker logs --details orange-frontstage-service
also can enter container check logs
docker container exec -it orange-frontstage-service /bin/bash
cd /usr/local/apache-tomcat-10.1.16/logs/
ls -la
cat logfile
Test API use curl command or use browser.
curl http://localhost:8080/main-0.0.1-SNAPSHOT/