mirror of
https://github.com/certbot/certbot.git
synced 2026-06-04 06:15:36 -04:00
add set_config_var
This commit is contained in:
parent
b21b66c0c0
commit
11b820c0e4
1 changed files with 14 additions and 0 deletions
|
|
@ -40,6 +40,7 @@ class Installer(plugins_common.Installer):
|
|||
super(Installer, self).__init__(*args, **kwargs)
|
||||
self.fixup = False
|
||||
self.config_dir = None
|
||||
self.proposed_changes = {}
|
||||
|
||||
def prepare(self):
|
||||
"""Prepare the installer.
|
||||
|
|
@ -426,6 +427,19 @@ class Installer(plugins_common.Installer):
|
|||
|
||||
return cmd
|
||||
|
||||
def set_config_var(self, name, value):
|
||||
"""Set the Postfix config parameter name to value.
|
||||
|
||||
This method only stores the requested change in memory. The
|
||||
Postfix configuration is not modified until save() is called.
|
||||
|
||||
:param str name: name of the Postfix config parameter
|
||||
:param str value: value to set the Postfix config parameter to
|
||||
|
||||
"""
|
||||
assert isinstance(name, str), "Invalid name value"
|
||||
assert isinstance(value, str), "Invalid key value"
|
||||
self.proposed_changes[name] = value
|
||||
|
||||
# def update_CAfile(self):
|
||||
# os.system("cat /usr/share/ca-certificates/mozilla/*.crt > " + self.ca_file)
|
||||
|
|
|
|||
Loading…
Reference in a new issue