docker搭建tomcat
Dockerfile内容如下:
#基于 centos:6 镜像 FROM centos:6 #信息 MAINTAINER hxguang <[email protected]> #安装 ssh-server ,vim RUN yum install -y openssh-server vim #把java与tomcat添加到容器中 ADD jdk1.7.0_80 /usr/local/jdk1.7.0_80 ADD apache-tomcat-7.0.73 /usr/local/tomcat #配置java与tomcat环境变量 ENV JAVA_HOME /usr/local/jdk1.7.0_80 ENV CLASSPATH $JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar ENV PATH $PATH:$JAVA_HOME/bin #暴露端口 EXPOSE 22 8080 #启动tomcat ENTRYPOINT /usr/local/tomcat/bin/startup.sh && tail -F /usr/local/tomcat/logs/catalina.out
相关推荐
王道革 2020-11-25
bwyyziq 2020-11-22
pigsmall 2020-11-19
changecan 2020-11-19
helloWorldAndYou 2020-11-16
nginxs 2020-11-14
红石丶 2020-11-13
WanKaShing 2020-11-12
yangkang 2020-11-12
滴水穿石点石成金 2020-11-12
张荣珍 2020-11-12
wuxunanjing 2020-11-11
魅惑青花瓷 2020-11-11
lihongtai 2020-11-09
yangkang 2020-11-09
worldsnow 2020-11-06
MichaelJScofield 2020-11-06
TaoTaoFu 2020-11-06