Dockerfile 647 B

12345678910111213141516171819
  1. #基于nginx镜像
  2. # FROM nginx-hide-versions
  3. # FROM centos7.2-nginx1.22.0:base-1.1
  4. FROM nginx:1.29.0
  5. #从dockerhub拉取nginx镜像
  6. # FROM registry-1.docker.io/library/nginx:1.22.1
  7. #将dist文件中的内容复制到 /usr/share/nginx/html/ 这个目录下面
  8. # RUN rm -rf /usr/share/nginx/html/dist
  9. COPY dist/ /usr/share/nginx/html/industry-18099
  10. # COPY dist/index.html /usr/share/nginx/html/index.html
  11. #用本地的 nginx.conf 配置来替换nginx镜像里的默认配置
  12. # COPY nginx.conf /usr/local/nginx/conf/nginx.conf
  13. COPY nginx.conf /etc/nginx/nginx.conf
  14. RUN chmod 777 -R /usr/share/nginx/html/
  15. RUN chmod 777 -R /etc/nginx/nginx.conf