Hi
I migrate my working Nextcloud from :
apache behind a nginx reverse proxy
to nginx behind same nginx reverse proxy
I get almost working result but horrible display :
see it here.
There are no erros in logs files.
Here is my frontend Nginx config :
server {
listen 80;
server_name cloud.nails.pl;
return 301 https://cloud.nails.pl$request_uri;
}
server {
listen 443;
server_name cloud.nails.pl;
add_header Strict-Transport-Security "max-age=15552000; includeSubDomains" always;
error_log /var/log/nginx/cloud.nails.pl.error.log;
access_log /var/log/nginx/cloud.nails.pl.access.log;
ssl on;
ssl_certificate /etc/letsencrypt/live/cloud.nails.pl/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/cloud.nails.pl/privkey.pem; # managed by Certbot
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
set $upstream 192.168.88.3;
location / {
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass_header Authorization;
proxy_pass http://$upstream;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_http_version 1.1;
proxy_set_header Connection "";
proxy_buffering off;
client_max_body_size 0;
proxy_read_timeout 36000s;
proxy_redirect off;
}
location = /.well-known/carddav {
return 301 $scheme://$host:$server_port/remote.php/dav;
}
location = /.well-known/caldav {
return 301 $scheme://$host:$server_port/remote.php/dav;
}
}
And here is my backend Nginx config :
server {
listen 80;
server_name 192.168.88.3;
index index.html index.php;
error_log /var/log/nginx/cloud.nails.pl.error.log;
access_log /var/log/nginx/cloud.nails.pl.access.log;
client_max_body_size 100m;
root /var/www/nc;
location = /favicon.ico {
log_not_found off;
access_log off;
}
location = /robots.txt {
allow all;
log_not_found off;
access_log off;
}
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
expires max;
log_not_found off;
}
location / {
try_files $uri $uri/ /index.php?$args;
}
location ~ \.php$
{
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/run/php/php8.0-fpm.sock;
}
}
I don’t even know what to enter in Google search bar to get a clue on what happen here.
Thanks for your ideas on solving it guys !