Repository navigation
Inelegant approach to support --renewer-config-file command-line argument - #447
Merged
Merged
Conversation
Contributor
|
LGTM 👍 |
Conflicts: letsencrypt/cli.py letsencrypt/client.py letsencrypt/interfaces.py
Contributor
Author
|
I edited my comment above to note that the correct field name is |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit allows the client to accept a
--renewer-config-fileargument which specifies the location of the renewer configuration file that provides defaults for where to save renewal-enrolled certs. These defaults supersede those that would otherwise have been provided byconstants.py. (The ability to do this was already available instorage.pybut there was previously no way to make use of it because there was no way for the options to be provided on the command line.)For integration testing, you can make a file, say
/tmp/tmp.muglQrnKEA, containing the following lines:Then if you invoke the client with
--renewer-config-file /tmp/tmp.muglQrnKEA, the renewer code will use these paths as the default location for saving stuff, in lieu of the defaults locations under/etc/letsencrypt. I think the client will be willing to createconfigs,archive, andliveif they don't already exist.Note that other parts of the code might still try to write files to
/etcfor historical reasons (which is now obsolete behavior that should be phased out), but those parts can be controlled by previously-existing command-line options like--work-dir. This new command-line option affects only the renewer enrollment functionality invoked viastorage.RenewableCert.new_lineage, which had previously insisted on writing to/etc/letsencryptand couldn't be induced to do otherwise.Fixes #436. Ought to be superseded by a comprehensive approach to #446 and possibly also a future client CLI redesign. Cc @jsha.