summaryrefslogtreecommitdiffstats
path: root/base/server
diff options
context:
space:
mode:
authorAde Lee <alee@redhat.com>2015-07-24 15:07:02 -0400
committerAde Lee <alee@redhat.com>2015-07-24 15:23:35 -0400
commit8a002e091841ceb52346f121d75db80e78735af2 (patch)
tree9c019105238b618712d66e8278cd8888b49db44c /base/server
parent318158217ae4cca9a761a582e74bfe339a1d0c13 (diff)
downloadpki-8a002e091841ceb52346f121d75db80e78735af2.tar.gz
pki-8a002e091841ceb52346f121d75db80e78735af2.tar.xz
pki-8a002e091841ceb52346f121d75db80e78735af2.zip
Fix code to add replicationdb password unless already present
The replicationdb password is an instance parameter and should be created by the first subsystem in the instance. This should happen independantly of whether replication is being set up in case it is needed to set up replication (as a master) later. Related to Ticket 1414
Diffstat (limited to 'base/server')
-rw-r--r--base/server/cms/src/org/dogtagpki/server/rest/SystemConfigService.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/base/server/cms/src/org/dogtagpki/server/rest/SystemConfigService.java b/base/server/cms/src/org/dogtagpki/server/rest/SystemConfigService.java
index e7a99601b..31891ca62 100644
--- a/base/server/cms/src/org/dogtagpki/server/rest/SystemConfigService.java
+++ b/base/server/cms/src/org/dogtagpki/server/rest/SystemConfigService.java
@@ -713,7 +713,7 @@ public class SystemConfigService extends PKIService implements SystemConfigResou
passwordFile = cs.getString("passwordFile");
psStore = CMS.createFileConfigStore(passwordFile);
psStore.putString("internaldb", data.getBindpwd());
- if (data.getSetupReplication()) {
+ if (StringUtils.isEmpty(psStore.getString("replicationdb", null))) {
psStore.putString("replicationdb", replicationPassword);
}
psStore.commit(false);