summaryrefslogtreecommitdiffstats
path: root/base/deploy/src/scriptlets/pkiparser.py
diff options
context:
space:
mode:
authorEndi Sukma Dewata <edewata@redhat.com>2012-11-28 13:12:24 -0500
committerEndi Sukma Dewata <edewata@redhat.com>2012-11-30 16:03:07 -0500
commit471a49326ee8755bf2440962a36a30f4df619a17 (patch)
treef10e197999be4d9d2c1e85be77d408b028bb2c8e /base/deploy/src/scriptlets/pkiparser.py
parent5e93dc2ce2c26c43d3e2f7e9a40cbf08507a5ea6 (diff)
downloadpki-471a49326ee8755bf2440962a36a30f4df619a17.tar.gz
pki-471a49326ee8755bf2440962a36a30f4df619a17.tar.xz
pki-471a49326ee8755bf2440962a36a30f4df619a17.zip
Simplified the configuration file using defaults.
Previously to create a subsystem the admin would have to copy the entire default deployment configuration, which contains many parameters, and then customize it. Now the deployment code has been changed such that the default config file will be used to provide the default values, so the admin will only need to provide the non-default parameters, thus reducing the size of the file. Sample configuration files are provided in /usr/share/pki/ deployment/config. Ticket #399
Diffstat (limited to 'base/deploy/src/scriptlets/pkiparser.py')
-rw-r--r--base/deploy/src/scriptlets/pkiparser.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/base/deploy/src/scriptlets/pkiparser.py b/base/deploy/src/scriptlets/pkiparser.py
index 438b23bd7..d05870e04 100644
--- a/base/deploy/src/scriptlets/pkiparser.py
+++ b/base/deploy/src/scriptlets/pkiparser.py
@@ -178,7 +178,7 @@ class PKIConfigParser:
deployed_pki_subsystem_path + "/" +\
"registry" + "/" +\
config.pki_subsystem.lower() + "/" +\
- config.PKI_DEPLOYMENT_DEFAULT_CONFIGURATION_FILE
+ config.PKI_DEPLOYMENT_CONFIGURATION_FILE
# always verify that configuration file exists
if not os.path.exists(config.pkideployment_cfg) or\
not os.path.isfile(config.pkideployment_cfg):
@@ -222,7 +222,9 @@ class PKIConfigParser:
self.pki_config = ConfigParser.ConfigParser()
# Make keys case-sensitive!
self.pki_config.optionxform = str
- self.pki_config.read(config.pkideployment_cfg)
+ self.pki_config.read([
+ config.PKI_DEPLOYMENT_DEFAULT_CONFIGURATION_FILE,
+ config.pkideployment_cfg])
config.pki_default_dict = self.pki_config.defaults()
pkilogging.sensitive_parameters = config.pki_default_dict['sensitive_parameters'].split()
config.pki_common_dict = dict(self.pki_config._sections['Common'])
@@ -2309,11 +2311,11 @@ class PKIConfigParser:
# Finalization name/value pairs
config.pki_master_dict['pki_deployment_cfg_replica'] =\
os.path.join(config.pki_master_dict['pki_subsystem_registry_path'],
- config.PKI_DEPLOYMENT_DEFAULT_CONFIGURATION_FILE)
+ config.PKI_DEPLOYMENT_CONFIGURATION_FILE)
config.pki_master_dict['pki_deployment_cfg_spawn_archive'] =\
config.pki_master_dict['pki_subsystem_archive_log_path'] + "/" +\
"spawn" + "_" +\
- config.PKI_DEPLOYMENT_DEFAULT_CONFIGURATION_FILE + "." +\
+ config.PKI_DEPLOYMENT_CONFIGURATION_FILE + "." +\
config.pki_master_dict['pki_timestamp']
config.pki_master_dict['pki_deployment_cfg_respawn_archive'] =\
config.pki_master_dict['pki_subsystem_archive_log_path'] + "/" +\