I could use some pointing in the right direction.
So far we have around 3 pet servers with a bunch of ad-hoc nginx configurations, written at first to expose port 80, and then auto-redirected with certbot after getting a certificate for those. Problem is, with those being ad-hoc and following no pattern/versioning whatsoever, they're at risk in case of a disaster.
I was thinking of versioning these with our infra as code project with ansible, but I can't figure out how to deal with the config files changing after certbot's execution. That is, let's say I add a new host. I add a .conf file to the nginx role we use, run ansible, and that installs the new host right? Then if I run certbot and redirect that new host, this file would change remotely, meaning that the next ansible execution would count it as a difference, and try to correct the file again. What would be the right thing to do to get around this?
Really interesting problem. Are you using docker or VMs?
Обсуждают сегодня