Created
October 6, 2018 18:47
-
-
Save manishjaingit/3d554cf1f3e536f6026a40f0a5b3bf83 to your computer and use it in GitHub Desktop.
setup lets encrypt in Ubuntu 16.04
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### To apply ssl certificate free via lets encrypt. ### | |
Step 1 | |
sudo add-apt-repository ppa:certbot/certbot | |
sudo apt-get update | |
sudo apt-get install python-certbot-nginx | |
sudo nano /etc/nginx/sites-available/default | |
# change serverName yourdomainname.com | |
sudo systemctl reload nginx | |
sudo ufw allow 'Nginx Full' | |
sudo ufw delete allow 'Nginx HTTP' | |
sudo ufw status | |
# if show inactive | |
sudo ufw enable | |
sudo certbot --nginx -d lmsindia.xyz -d www.lmsindia.xyz | |
# give some question answer and then run below command to renew the ssl. | |
sudo certbot renew --dry-run |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
After successfully installation of ssl certificate make sure to comment the #port80 line in ssl server block, which creates after the ssl