letsencrypt_apache.augeas_configurator
¶
Class of Augeas Configurators.
-
class
letsencrypt_apache.augeas_configurator.
AugeasConfigurator
(*args, **kwargs)[source]¶ Bases:
letsencrypt.plugins.common.Plugin
Base Augeas Configurator class.
Variables: - config – Configuration.
- aug – Augeas object
- save_notes (str) – Human-readable configuration change notes
- reverter – saves and reverts checkpoints
-
check_parsing_errors
(lens)[source]¶ Verify Augeas can parse all of the lens files.
Parameters: lens (str) – lens to check for errors Raises: .errors.PluginError – If there has been an error in parsing with the specified lens.
-
save
(title=None, temporary=False)[source]¶ Saves all changes to the configuration files.
This function first checks for save errors, if none are found, all configuration changes made will be saved. According to the function parameters. If an exception is raised, a new checkpoint was not created.
Parameters: Raises: .errors.PluginError – If there was an error in Augeas, in an attempt to save the configuration, or an error creating a checkpoint
-
_log_save_errors
(ex_errs)[source]¶ Log errors due to bad Augeas save.
Parameters: ex_errs (list) – Existing errors before save
-
recovery_routine
()[source]¶ Revert all previously modified files.
Reverts all modified files that have not been saved as a checkpoint
Raises: .errors.PluginError – If unable to recover the configuration
-
revert_challenge_config
()[source]¶ Used to cleanup challenge configurations.
Raises: .errors.PluginError – If unable to revert the challenge config.