Digital Ocean HTTPS on Instances. Invalid certs from letsencrypt-nginx-proxy-companion

I have deployed Flowfuse on Digital Ocean via the 1-click droplet. Got everything setup with DNS ect.
Flowfuse and my first instance both have working HTTPS. I didn’t have to do anything to get this working. Chrome shows the cert org as Let’s Encrypt.
My second instance shows a 500 internal error. If i remove https with http I can get to the instance. The cert org shows as letsencrypt-nginx-proxy-companion and the cert is not valid.

How do I go about rectifying this?
Thanks,

This may just be the default cert that is presented while the letsencrypt certificate is being provisioned, if you give it another 60 seconds and try reloading the https URL does it work?

I don’t think so mate, had the instance up about 3 hours.
If I make another instance it has the same issue too.

In that case we will probably need to see the logs from the nginx contain on the droplet.

If you log into the droplet via ssh and run

docker logs flowforge_nginx_1

It should dump the logs

Ah, so got “Error response from daemon: No such container: flowforge_nginx_1”

I’ve installed portainer for managing a few other dockers.

OK, so the flowforge-acme-1 container is what handles getting certificates and should be running, so we need to find out why that failed.

Looks like I transposed - for _

Please provide the logs for the flowforge-acme-1 and the flowforge-ngxin-1 containers.

I started the flowforge-acme-1 docker to then grab the logs and as I was watching them via portainer it grabbed a cert and is now working fine!
Not sure why it exited in the first place but it seams to be okay now. I’ll keep an eye on it and see if it stops again

Thanks mate

Edit:
Rebooted the droplet and found the acme docker exited again. Turns out it’s restart policy was set to none. I’ve changed it to unless stopped. Maybe there’s a reason it’s set to none by default?