Web 服务器宕机,但 nginx 状态良好且配置良好

Web 服务器宕机,但 nginx 状态良好且配置良好

我在 unbuntu 22.04 lts 上。我在 /etc/nginx/sites-available 中创建了另一个配置文件 .conf,此后我的网站就关闭了。但是当我执行命令检查 nginx 状态是否良好时,我的配置文件也很好。

server_tokens off;

server {
    listen 80;
    server_name domain.fr;
    return 301 https://$server_name$request_uri;
}

server {
    listen 443 ssl http2;
    server_name domain.fr;

    root /var/www/portfolio;
    index index.html;


    sendfile off;

    # SSL Configuration - Replace the example <domain> with your domain
    ssl_certificate /etc/letsencrypt/live/domain.fr/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/domain.fr/privkey.pem;
    ssl_session_cache shared:SSL:10m;
    ssl_protocols TLSv1.2 TLSv1.3;
    ssl_ciphers "ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384";
    ssl_prefer_server_ciphers on;

}```

And "Welcome to nginx" page work but only on my local ip and i don't have my website


i have write it above

相关内容