Browse Source

需求:调整镜像运行的用户名

lijie 2 years ago
parent
commit
a81ce672fe
1 changed files with 6 additions and 6 deletions
  1. 6 6
      docker/dockerfiles/dmp-rwd/Dockerfile

+ 6 - 6
docker/dockerfiles/dmp-rwd/Dockerfile

@@ -18,16 +18,16 @@ ARG WORKER_HOME
 #执行的命令
 RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezon
 RUN yum install -y unzip zip wget telnet tzdata
-RUN mkdir -p $WORKER_HOME/config
+RUN mkdir -p $WORKER_HOME/app/config
 RUN groupadd docker
 RUN useradd -d $WORKER_HOME -g docker -m -s /bin/bash docker
 #设置工作目录
-WORKDIR $WORKER_HOME
+WORKDIR $WORKER_HOME/app
 #复制文件到容器内
-COPY *.jar $WORKER_HOME/app.jar
-COPY entrypoint.sh $WORKER_HOME/
-COPY version.txt $WORKER_HOME/
-COPY config/* $WORKER_HOME/config/
+COPY *.jar $WORKER_HOME/app/app.jar
+COPY entrypoint.sh $WORKER_HOME/app/
+COPY version.txt $WORKER_HOME/app/
+COPY config/* $WORKER_HOME/app/config/
 RUN chmod 755 entrypoint.sh
 RUN chown -R docker:docker *
 #查看上述复制的文件,是否复制成功