with my Nginx configuration (see below) redirecting from http to https works fine when accessing the page (http://example.com/) with Firefox. But for some strange reason it does not work with Chrome.
server {
listen 80;
server_name example.com;
return 301 https://$server_name$request_uri;
}
server {
listen 443 ssl;
server_name example.com;
server_tokens off;
ssl_certificate /etc/nginx/ssl/example.com_fullchain1.pem;
ssl_certificate_key /etc/nginx/ssl/example.com_privkey1.pem;
ssl_session_cache builtin:1000 shared:SSL:10m;
ssl_protocols TLSv1.3;
ssl_ciphers "HIGH !aNULL !eNULL !EXPORT !CAMELLIA !DES !MD5 !PSK !RC4";
ssl_prefer_server_ciphers on;
access_log /var/log/nginx/httpd-example.com.log;
}
Uuh, and when I look at the requests being send in the Dev Tools, it seems that Firefox (although I request http://example.com) just asks for https://example.com directly. Am I missing something?