是否可以在两个单独的块中定义单个nginx位置?
例如:
server {
listen *:80;
server_name someserver;
location / {
proxy_cache off;
}
location /assets {
proxy_cache mycache;
}
# What do I need to do to get this second root location
# to append to the 1st? If it's even possible.
location / {
我试图指向我的码头集装箱域名。在我们的路由器中,我们将端口80转发到192.168.1.101 (服务器码头正在运行)
然而,容器IP地址显示如下
"nextjs-docker-pm2-nginx-master-nextjs-1:172.18.0.2/16"
"nextjs-docker-pm2-nginx-master-nginx-1:172.18.0.4/16"
CONTAINER ID IMAGE COMMAND CREATED ST