Renewing certificate with Letsencrypt docker

  • I've got Nextcloud/Letsencrypt working perfectly... Got an email today saying my Letsencrypt cert is going to expire and needs to be renewed. Are there instructions somewhere on how to do this?

  • simply restart letsencrypt docker

  • Really that's it?


    Do I need to do this the day the cert expires, or does it happen anytime the container is restarted? I usually shut down my NAS during the evening while I work... so does it update every time I boot my NAS or does it just update once it expires?


    I figured w/ the email I was getting that I was going to have to do something.

  • check the letsencrypt log.

  • I renewed Letsencrypt last night. There is a plug-in for that that is suppose to manage re-certs automatically but I never figured out how to set it up. I didn’t know what to use as a file path.


    I can’t remember who gave these steps on the forum but they have worked for me. This will work for any docker you wish to upgrade. Before you do anything back up your system drive/stick/card so you will have a way to back out of a mistake.


    I also like to take a screen shot of the current container so I can recall the settings. Select the container and click the modify button to take some screenshots. When finished, cancel out of the container so as not to change anything or you are toast. Now, here’s the list:


    1. Pull the image from docker hub. Don’t forget to insert the correct tag.
    2. The container still runs on your older version and the name of the old image turns into a hash.
    3. Stop the old container.
    4. Select this container and press copy and give it a new name because you can't use the old name. When finished save the container.
    5. Delete the old container.
    6. Delete the old image.
    7. Update containers that use this container as a mounted volume (like plex uses delunge, Radarr and Sonarr mounted volumes from other containers)
    8. Last of all, for Letsencrypt, go to your command line and enter docker logs -f letsencrypt (or whatever you named the new container).


    That did it for me. Your mileage may vary. Someone; anyone; chime in and correct me if I’m wrong.


    One thing I recall when filling in the new container is that most of the lines will already be filled in. In the Mode field at the top my-net will be there. Change that to Bridge. That field picks up the extra argument from the bottom of the form once the container is saved.

    RAID is NOT a backup and not useful for most home users. Rsync makes true backup and restoration stupid easy, and it's built right in to OMV. Use this command in a Scheduled Job: rsync -av --delete /srv/dev-disk-by-label-NAMEofSOURCEdisk/ /srv/dev-disk-by-label-NAMEofDESTINATIONdisk/

    Hardware: OMV 5 (current) - NanoPi M4: Nextcloud, Plex, & Heimdall - Acer Aspire T180: backup - Odroid XU4: Pi-Hole (DietPi) - Odroid HC2, Raspberry Pi 3B+, and HP dx2400: testing.

  • Well that’s one way to do it.

    RAID is NOT a backup and not useful for most home users. Rsync makes true backup and restoration stupid easy, and it's built right in to OMV. Use this command in a Scheduled Job: rsync -av --delete /srv/dev-disk-by-label-NAMEofSOURCEdisk/ /srv/dev-disk-by-label-NAMEofDESTINATIONdisk/

    Hardware: OMV 5 (current) - NanoPi M4: Nextcloud, Plex, & Heimdall - Acer Aspire T180: backup - Odroid XU4: Pi-Hole (DietPi) - Odroid HC2, Raspberry Pi 3B+, and HP dx2400: testing.

  • certbot can be started from a shell when you bash into the letsencrypt container. So you need to start with shell-in-a-box or whatever tool you use to get on the docker-machine and do a docker exec -it <name of your letsencrypt docker> bash. Then you are into the letsencrypt docker and you should be able to use command certbot somehow. I am also struggling with this thing. I would not through away containers anyway!

  • certbot can be started from a shell when you bash into the letsencrypt container. So you need to start with shell-in-a-box or whatever tool you use to get on the docker-machine and do a docker exec -it <name of your letsencrypt docker> bash. Then you are into the letsencrypt docker and you should be able to use command certbot somehow. I am also struggling with this thing. I would not through away containers anyway!

    I've not done it yet as it's not due to repeat, but it would appear pretty simple with certbot


    https://forum.openmediavault.o…?postID=222302#post222302

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!