Skip to content

Add lego_version parameter and update to lego 5.x#5

Merged
KatrinIhler merged 3 commits into
mainfrom
fixes-and-improvements
Jun 9, 2026
Merged

Add lego_version parameter and update to lego 5.x#5
KatrinIhler merged 3 commits into
mainfrom
fixes-and-improvements

Conversation

@LukasKalbertodt

Copy link
Copy Markdown
Member

See commits.

Re the 5.x update: See https://ldez.github.io/blog/2026/05/11/lego-v5/ for an overview. I'm pretty sure this role can be simplified a bit with 5.x in mind. 5.x unified renew and run commands and also supports config files, so maybe the lego-renew.sh might not be necessary anymore? But I didn't have the time to look further into this. I just did the minimum to make it work with 5.x

Always using `latest` is not a good idea. It makes the Ansible playbook
not reproducible easily (see whole lock file discussion). But it also
runs the risk of lego releasing a new major version that this role is
incompatible with. This happened with the release of lego 5.

I decided to make this variable required for exactly those reasons.
The CLI changed quite a bit, combining the `run` and `renew` commands
into one.
@LukasKalbertodt LukasKalbertodt force-pushed the fixes-and-improvements branch from 333f959 to 11ad9a6 Compare June 3, 2026 08:44
This is just strictly more powerful than what we had before. Sometimes
it's necessary to do multiple things as a hook. And of course, the
user of this role could write this script file somewhere, but that is
usually very inconvenient as it has to be done before this role runs,
but then where to put the script? Integrating it into this role solves
this.
@KatrinIhler KatrinIhler merged commit 925d17b into main Jun 9, 2026
4 checks passed
@LukasKalbertodt LukasKalbertodt deleted the fixes-and-improvements branch June 9, 2026 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants