制作 OpenResty 项目 docker 镜像踩坑

2021/11/17

Nginx 启动需要配置前台运行

https://github.com/docker-library/docs/tree/master/nginx#complex-configuration

# ... 省略 ...

CMD ["nginx", "-g", "daemon off;"]

容器网络内域名无法解析

https://stackoverflow.com/a/37656784/7450306

要配置 resolver

http { 
    resolver 127.0.0.11 ipv6=off; 
}