如何更改dashboard端口?
Closed this issue · 2 comments
xiao-k233 commented
希望能添加对dashboard端口的设置,我使用端口映射80到外网81无法访问
amefs commented
可以直接修改 /etc/nginx/sites-enabled/default
中的监听端口
listen 81 default_server;
listen [::]:81 default_server;
如果你的443端口依然不能使用则还需要修改为如下内容,删除https支持,但在公开网络中不建议取消https加密:
server {
listen 81 default_server;
listen [::]:81 default_server;
server_name _;
location /.well-known {
alias /srv/.well-known;
allow all;
default_type "text/plain";
autoindex on;
}
client_max_body_size 40M;
server_tokens off;
root /srv/;
index index.html index.php index.htm;
# resolve multi-redirect
if ($request_uri ~ "^[^?]*?//") {
rewrite "^" $scheme://$host$uri permanent;
}
location ~ \.php$
{
fastcgi_read_timeout 240;
fastcgi_pass unix:/run/php/php7.4-fpm.sock;
include snippets/fastcgi-php.conf;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
include /etc/nginx/apps/*.conf;
location ~ /\.ht {
deny all;
}
location /fancyindex {
}
}
xiao-k233 commented
我是家宽啊,443封了的
http也没事吧,我觉得应该没人闲着没事给我搞中间人攻击
…---原始邮件---
发件人: ***@***.***>
发送时间: 2023年12月10日(周日) 下午4:54
收件人: ***@***.***>;
抄送: ***@***.******@***.***>;
主题: Re: [amefs/quickbox-lite] 如何更改dashboard端口? (Issue #213)
可以直接修改 /etc/nginx/sites-enabled/default 中的监听端口
listen 81 default_server; listen [::]:81 default_server;
如果你的443端口依然不能使用则还需要修改为如下内容,删除https支持,但在公开网络中不建议取消https加密:
server { listen 80 default_server; listen [::]:80 default_server; server_name _; location /.well-known { alias /srv/.well-known; allow all; default_type "text/plain"; autoindex on; } client_max_body_size 40M; server_tokens off; root /srv/; index index.html index.php index.htm; # resolve multi-redirect if ($request_uri ~ "^[^?]*?//") { rewrite "^" $scheme://$host$uri permanent; } location ~ \.php$ { fastcgi_read_timeout 240; fastcgi_pass unix:/run/php/php7.4-fpm.sock; include snippets/fastcgi-php.conf; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; } include /etc/nginx/apps/*.conf; location ~ /\.ht { deny all; } location /fancyindex { } }
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>