I would like to setup a Magento Platform on a Server. I use Centos and nginx and would like to redirect all http connections to https I already set on nginx domain.conf a http https redirect and thats works fine but how can I be sure that all connections are secured. I ask because if I use also HSTS the very first request may still be http.
A review of my example.org.conf file
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name example.org www.example.org;
return 301 https://$server_name$request_uri;
}
server {
#listen 80 reuseport;
#listen 443 http2 ssl reuseport;
listen 443 ssl;
#listen 80;
...
...
}
So again I how can I be sure that all connections are secured? The second reason I ask is I noticed that If I open the domain with a smartphone with slow mobile data speed, It starts with just for a second not secure url or I am just wrong?
Hope you could give me an advice