docker 安装nginx

Dockerfile 文件

version: '3'


services:
  nginx:
    image: nginx
    container_name: nginx
    volumes:
    # 映射主机./conf.d目录到容器/etc/nginx/conf.d目录
      - "$PWD/conf.d:/etc/nginx/conf.d"
    ports:
      - 8888:80

posted @ 2021-02-08 11:43  鲁哒哒  阅读(77)  评论(0编辑  收藏  举报