summaryrefslogtreecommitdiffstats
path: root/install/tools/ipa-replica-prepare
diff options
context:
space:
mode:
authorAde Lee <alee@redhat.com>2012-09-19 23:35:42 -0400
committerMartin Kosek <mkosek@redhat.com>2012-11-23 12:19:19 +0100
commit18a210996dc47dbc9979e5ee0bb9f184c22eb173 (patch)
tree41a99a8d78e7f32a5372518f36415ff2f15ca466 /install/tools/ipa-replica-prepare
parent7960b5c67f0577e305d9fd86564b19957872d0e3 (diff)
downloadfreeipa-18a210996dc47dbc9979e5ee0bb9f184c22eb173.tar.gz
freeipa-18a210996dc47dbc9979e5ee0bb9f184c22eb173.tar.xz
freeipa-18a210996dc47dbc9979e5ee0bb9f184c22eb173.zip
Changes to use a single database for dogtag and IPA
New servers that are installed with dogtag 10 instances will use a single database instance for dogtag and IPA, albeit with different suffixes. Dogtag will communicate with the instance through a database user with permissions to modify the dogtag suffix only. This user will authenticate using client auth using the subsystem cert for the instance. This patch includes changes to allow the creation of masters and clones with single ds instances.
Diffstat (limited to 'install/tools/ipa-replica-prepare')
-rwxr-xr-xinstall/tools/ipa-replica-prepare8
1 files changed, 6 insertions, 2 deletions
diff --git a/install/tools/ipa-replica-prepare b/install/tools/ipa-replica-prepare
index d67ed818e..f9d0eb646 100755
--- a/install/tools/ipa-replica-prepare
+++ b/install/tools/ipa-replica-prepare
@@ -209,8 +209,8 @@ def save_config(dir, realm_name, host_name,
config.set("realm", "destination_host", dest_host)
config.set("realm", "subject_base", str(subject_base))
config.set("realm", "version", str(version.NUM_VERSION))
- fd = open(dir + "/realm_info", "w")
- config.write(fd)
+ with open(dir + "/realm_info", "w") as fd:
+ config.write(fd)
def remove_file(fname, ignore_errors=True):
try:
@@ -371,6 +371,10 @@ def main():
except errors.CertificateOperationError, e:
print "%s" % e
sys.exit(1)
+ print "Saving dogtag Directory Server port"
+ port_fname = dir + "/dogtag_directory_port.txt"
+ with open(port_fname, "w") as fd:
+ fd.write("%s\n" % str(dogtag.configured_constants().DS_PORT))
if options.http_pin:
passwd = options.http_pin