Where Do I install the SSL for a production site?

Yeah, disable the default nginx page as it’s taking up the default port at 80, I gues it’s at /etc/nginx/conf.d/default.conf

Okay so I left the default.conf untact.

I modified the frappe.conf with the following.

server {
                    listen 80 ;
                    listen 443 ssl ;
                    client_max_body_size 4G;
                                            server_name 104.197.189.126;
                    #FORCE HTTP
                     if ($scheme = http) {
                     return 301 https://$server_name$request_uri;
                    }
                    ssl on;
                    ssl_certificate      /my/path/to/my/certificate.crt;
                    ssl_certificate_key  /my/path/to/my/private_key.key;

It worked. If you go to http://104.197.189.126, it will redirecto to HTTPS.

Thanks @pdvyas @DrTrills @bohlian

4 Likes

Please who can assist me in SSL installation, I got error while trying to install and my site stop working after the error

I used
sudo bench setup lets-encrypt erp.example.com

and it worked.

used this step-by-step guide. (find Let’s encript is close to the end):
https://www.vultr.com/docs/how-to-install-erpnext-open-source-erp-on-ubuntu-17-04-22771

1 Like

Refer this link,