#Change Domain

15 messages · Page 1 of 1 (latest)

iron nebula
#

Hi can someone say me how to completely change my Domain from domain.tld to newdomain.tld

iron nebula
#

I did that and now I have the problem that you can still access the site with the old domain and I cannot enter the smtp host (save)

iron nebula
#

Ya

#

I did systemctl restart nginx

clear grottoBOT
#

You'll need to grab the error logs from the Panel. The following command uploads the last 100 lines of this day's log to our pastebin and provides a link you can share.
tail -n 100 /var/www/pterodactyl/storage/logs/laravel-$(date +%F).log | nc pteropaste.com 99

crude swallow
iron nebula
crude swallow
#

maybe this solves the problem

iron nebula
#

    server_name newdomain.tld;

    root /var/www/pterodactyl/public;
    index index.html index.htm index.php;
    charset utf-8;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location = /favicon.ico { access_log off; log_not_found off; }
    location = /robots.txt  { access_log off; log_not_found off; }

    access_log off;
    error_log  /var/log/nginx/pterodactyl.app-error.log error;

    # allow larger file uploads and longer script runtimes
    client_max_body_size 100m;
    client_body_timeout 120s;

    sendfile off;

    location ~ \.php$ {
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_pass unix:/run/php/php8.0-fpm.sock;
        fastcgi_index index.php;
        include fastcgi_params;
        fastcgi_param PHP_VALUE "upload_max_filesize = 100M \n post_max_size=100M";
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param HTTP_PROXY "";
        fastcgi_intercept_errors off;
        fastcgi_buffer_size 16k;
        fastcgi_buffers 4 16k;
        fastcgi_connect_timeout 300;
        fastcgi_send_timeout 300;
        fastcgi_read_timeout 300;
    }

    location ~ /\.ht {
        deny all;
    }

    listen [::]:443 ssl ipv6only=on; # managed by Certbot
    listen 443 ssl; # managed by Certbot
    ssl_certificate /etc/letsencrypt/live/newdomain.tld/fullchain.pem; # managed by Certbot
    ssl_certificate_key /etc/letsencrypt/live/newdomain.tld/privkey.pem; # managed by Certbot
    include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
    ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot

}
server {
    if ($host = newdomain.tld) {
        return 301 https://$host$request_uri;
    } # managed by Certbot


    listen 80;
    listen [::]:80;

    server_name newdomain.tld;
    return 404; # managed by Certbot


}```
#

that is my current nginx config

past pine
#

You will need to create a different server block (both http and https) to catch requests to other domains, otherwise nginx will response with the first/default website.

#

SMTP not saving is unrelated, and is a bug that has been reported on github