server{
listen 8099;
server_name 127.0.0.1:8099;
root /opt/project/package/dist;
location /api/ {
proxy_pass http://localhost:127.0.0.1:8099;
}
}
invalid number of arguments in "proxy_pass" directive in /etc/nginx/nginx.conf
今天配置报这个错,说明proxy_pass这后面写错了,原来是127.0.0.1:127.0.0.1:8099改为http://localhost:127.0.0.1:8099这个就可以了,难道我的本地不能写数字,奇怪,记录下