version9
1
This commit is contained in:
@@ -2,6 +2,12 @@ FROM nginx:alpine
|
||||
|
||||
MAINTAINER anfioo
|
||||
|
||||
# 1. 创建 Nginx 日志目录(避免启动时日志文件不存在报错)
|
||||
RUN mkdir -p /var/log/nginx \
|
||||
&& touch /var/log/nginx/access.log \
|
||||
&& touch /var/log/nginx/error.log
|
||||
|
||||
|
||||
# 把当前目录下的 nginx.conf 复制到容器的 Nginx 配置目录
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
|
||||
|
||||
Reference in New Issue
Block a user