Tutorial First things to do after getting a VPS (Debian 8) part 2

luckyhemanth

Member
Jun 6, 2017
33
83
37
Installing ssl certificates is important to get urself a green lock :p
-> login to ssh as root
->type the following commands in the same order..
1) apt-get install sudo
2) echo 'deb http://ftp.debian.org/debian jessie-backports main' | sudo tee /etc/apt/sources.list.d/backports.list
3) sudo apt-get update
4) sudo apt-get install python-certbot-apache -t jessie-backports
5) sudo nano /etc/apache2/sites-available/000-default.conf

->now here fill it like this
<VirtualHost *:80>
. . .
ServerName yourdomain.com
ServerAlias www.yourdomain.com
. . .
</VirtualHost>

type the commands in the ssh as root
6) sudo systemctl restart apache2
7) sudo certbot --apache

-> to get those certificates for life time u have to do a simple process
8) sudo crontab -e
choose 1 st option
Include the following content at the end of the crontab, all in one line
30 2 * * 1 /usr/bin/certbot renew >> /var/log/le-renew.log
-> save the file by pressing "F2" then press "Y" then hit Enter key
9) service apache2 restart


done njoy your lifetime ssl certificates :)
hit like if you like this tutorial
 

Asphyxia

Owner
Administrator
Apr 25, 2015
1,845
2
2,199
327
This could go inside website tutorials perhaps? It is useful if you are looking to spin up your own web server that is Linux-based. I would appreciate a side-by-side tutorial that goes on about setting up a web server on Linux and Windows, along with SSL certs on both. But since it is also on a Linux server, I can see how it could also fall into this area.

That is the tricky thing with topics like this, it is a mix. Great tutorial though!
 
Top