Quantcast
Channel: Nginx Forum - Other discussion
Viewing all articles
Browse latest Browse all 972

http to https not working.

$
0
0
Hello. i installed nginx version: nginx/1.16.1
created virtual host and added both http and https. when i want to enter app without https, it does not work. but when i add https to app address it works. my virtual host conf:
server {
listen ip address:80;
server_name domain_name;
return 301 https://$server_name$request_uri;
}



server {
listen ip_address:4433;
server_name domain name;
root /var/www/app_name/public;
index index.php index.html index.htm;
ssl on;

ssl_certificate /etc/nginx/ssl/cert-2.cer;

ssl_certificate_key /etc/nginx/ssl/private2.key;

Viewing all articles
Browse latest Browse all 972

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>