Home  >  Article  >  Operation and Maintenance  >  How to upgrade the tomcat version in docker

How to upgrade the tomcat version in docker

王林
王林Original
2020-04-14 15:37:304598browse

How to upgrade the tomcat version in docker

1. View the mounting information of the current tomcat container

docker inspect tomcat

2. Pull the latest image

docker pull tomcat

3. Then stop the current tomcat container

docker stop tomcat

5 and run the latest version of tomcat

docker run -d \
-v /server/demo:/usr/local/tomcat/webapps \
-v /server/logs:/mnt/applog \
-e TZ="Asia/Shanghai" \
--privileged=true \
--name tomcat_new \
-p 8080:8080 \
<container_id>

and it will run successfully.

Recommended tutorial: docker tutorial

The above is the detailed content of How to upgrade the tomcat version in docker. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn