1. 获取镜像
# 查看可用的稳定版本
sudo docker search tomcat
sudo docker pull tomcat
sudo docker image ls |grep tomcat
2. 启动容器
# 启动tomcat
docker run -p 8080:8080 tomcat -d --name tomcat
# 上传cas到tomcat
docker cp cas.war tomcat:/usr/local/tomcat/webapps
sudo docker start tomcat
sudo docker restart tomcat
sudo docker stop tomcat
sudo docker rm tomcat
Web UI:http://192.168.0.99:8080/cas