DEV Community

Discussion on: Pagekite: expose your team's localhosts to the world under your own domain

Collapse
 
voarsh2 profile image
voarsh2

Thanks for the useful tutorial, can you explain this?

Generate a cert + key file for Pagekite
An additional step is required here because Pagekite expects the certificate and its private key to be in the same file, but LetsEncrypt generates them separately. This is easy enough:
$ sudo cat \
/etc/letsencrypt/live/dev.skoach.com/fullchain.pem \
/etc/letsencrypt/live/dev.skoach.com/privkey.pem \
| sudo tee /etc/letsencrypt/live/dev.skoach.com/keycert.pem > /dev/null
Just remember to run this after every time you renew your certificates. Take special care if you're auto-renewing.

Does this command need to be run at renewal?

Collapse
 
jmnsf profile image
João Ferreira

Yep! It does. Pagekite expects a single file with the SSL certificate and private key, but letsencrypt creates separate files for all those. They're just text files though, so we can just concatenate their contents.

It's a bit of a chore, but you can add hooks to letsencrypt to do that: certbot.eff.org/docs/using.html#pr...