大家好,今天来分享使用docker部署Tomcat服务器
首先呢,大家可以去dicker 官网上去看
第一步:
拉取镜像
你可以不指定版本标签(默认下下载最新的,我这个时候,最新的是10)
[root@localhost ~]# docker pull tomcat:9.0
9.0: Pulling from library/tomcat
0e29546d541c: Pull complete
9b829c73b52b: Pull complete
cb5b7ae36172: Pull complete
6494e4811622: Pull complete
668f6fcc5fa5: Pull complete
dc120c3e0290: Pull complete
8f7c0eebb7b1: Pull complete
77b694f83996: Pull complete
7662046c36cb: Pull complete
b93639122cb4: Pull complete
Digest: sha256:cd96d4f7d3f5fc4d3bc1622ec678207087b8215d55021a607ecaefba80b403ea
Status: Downloaded newer image for tomcat:9.0
docker.io/library/tomcat:9.0
查看镜像
[root@localhost ~]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
nginx latest 605c77e624dd 2 months ago 141MB
tomcat 9.0 b8e65a4d736d 2 months ago 680MB
mysql latest 3218b38490ce 2 months ago 516MB
hel