DEV Community

Arshan Nawaz
Arshan Nawaz

Posted on

How to Enable free SSL in Your Domain Hosted on Remote Server or VPS ( only on domain if you have, not in server_ip )

Install Certbot and it’s Nginx plugin

sudo apt install certbot python3-certbot-nginx
Enter fullscreen mode Exit fullscreen mode

Verify Web Server Ports are Open and Allowed through Firewall

sudo ufw status verbose
Enter fullscreen mode Exit fullscreen mode

Obtain an SSL certificate

sudo certbot --nginx -d your_domain.com -d www.your_domain.com -d api.your_domain.com -d admin.your_domain.com -d www.admin.your_domain.com
Enter fullscreen mode Exit fullscreen mode

Check Status of Certbot

sudo systemctl status certbot.timer
Enter fullscreen mode Exit fullscreen mode

Dry Run SSL Renewal

sudo certbot renew --dry-run
Enter fullscreen mode Exit fullscreen mode

Top comments (0)