OneBite.Dev - Coding blog in a bite size

Renew SSL certificate Let's encrypt after Laravel Forge expired

When your subscription expired at Laravel forge, don't forget to reassign SSL certificate manually from your server

I wonder what happen “when my Laravel Forge subscription expired”? apparently:

Auto renew is stopped

Auto renewal for the certification is stopped as the Laravel forge service stopped.

How to renew / recreate your SSL certification

There’s no magic behind it. We just need to create new Let’s encrypt certification like when we spin up own server and install it there. Here are the steps:

SSH to your server

you must remember (save!) your forge password.

ssh forge@yourdomain.com

use forge user. If you don’t save your password, ask for reset password from your server provider

Install Certbot

sudo apt install certbot python3-certbot-nginx

Install SSL certificate

Depend on your need, if you want www domain as well

sudo certbot --nginx -d example.com -d www.example.com

if not

sudo certbot --nginx -d example.com 

Verify auto renewal

sudo systemctl status certbot.timer

test with

sudo certbot renew --dry-run

Detail source from: How To Secure Nginx with Let’s Encrypt on Ubuntu 20.04 , so you might want to adjust based on your ubuntu version.

That’s it

Hope your site is back again!

laravel devops