This is my nginx config:
server {
listen 80;
server_name forum.exemple.com;
location / {
proxy_pass http://unix:/var/discourse/shared/standalone/nginx.http.sock:;
proxy_set_header Host $http_host;
proxy_http_version 1.1;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
auth_basic "Staff only";
auth_basic_user_file /etc/nginx/.htpasswd/.htpasswd-staff;
}
access_log /var/log/nginx/forum_access.log;
error_log /var/log/nginx/forum_error.log;
}
The thing is, it’s CloudFlare who make the https redirect rules. So I have to listen the port 80 in nginx, else it doesn’t work…
The case “Force https” is not active in admin. Should I ?