server {
listen 8089; # 端口号
server_name localhost; # 设置为localhost,生产环境默认渲染为服务器地址
root /www/wwwroot/img; # 图片目录
# Load configuration files for the default server block.
include /etc/nginx/default.d/*.conf;
error_page 404 /404.html;
location = /40x.html {
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
}
}
云服务器开放8089端口
宝塔开放8089
ip:端口(8089)/文件名