summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAde Lee <alee@redhat.com>2016-02-10 07:01:14 -0500
committerAde Lee <alee@redhat.com>2016-02-17 15:40:54 -0500
commit944c44b7f1805fecbadfc31689d66f4c92e59272 (patch)
tree4d63d1c07f35da248fc639a55f68a1b1e4fb8bac
parent6947854a3ab6ee4f296a5f97850f5521572683a1 (diff)
downloadpki-944c44b7f1805fecbadfc31689d66f4c92e59272.tar.gz
pki-944c44b7f1805fecbadfc31689d66f4c92e59272.tar.xz
pki-944c44b7f1805fecbadfc31689d66f4c92e59272.zip
Modify dnsdomainname test in pkispawn
We do a check for the dnsdomainname, which fails in Openstack CI because this is not set. Instead of exiting, default to the hostname.
-rw-r--r--base/server/python/pki/server/deployment/pkimessages.py2
-rwxr-xr-xbase/server/sbin/pkidestroy2
-rwxr-xr-xbase/server/sbin/pkispawn2
3 files changed, 3 insertions, 3 deletions
diff --git a/base/server/python/pki/server/deployment/pkimessages.py b/base/server/python/pki/server/deployment/pkimessages.py
index b16051b6c..b58915fe2 100644
--- a/base/server/python/pki/server/deployment/pkimessages.py
+++ b/base/server/python/pki/server/deployment/pkimessages.py
@@ -69,7 +69,7 @@ PKI_DIRECTORY_ALREADY_EXISTS_NOT_A_DIRECTORY_1 = \
PKI_DIRECTORY_MISSING_OR_NOT_A_DIRECTORY_1 = \
"Directory '%s' is either missing or is NOT a directory!"
PKI_DNS_DOMAIN_NOT_SET = \
- "A valid DNS domain name MUST be established to use PKI services!"
+ "DNS domain name has not been set - using the hostname instead."
PKI_FILE_ALREADY_EXISTS_1 = "File '%s' already exists!"
PKI_FILE_ALREADY_EXISTS_NOT_A_FILE_1 = \
"File '%s' already exists BUT it is NOT a file!"
diff --git a/base/server/sbin/pkidestroy b/base/server/sbin/pkidestroy
index 032c97984..12d37f2f3 100755
--- a/base/server/sbin/pkidestroy
+++ b/base/server/sbin/pkidestroy
@@ -91,7 +91,7 @@ def main(argv):
config.pki_dns_domainname = dnsdomainname
if not len(config.pki_dns_domainname):
print(log.PKI_DNS_DOMAIN_NOT_SET)
- sys.exit(1)
+ config.pki_dns_domainname = config.pki_hostname
except subprocess.CalledProcessError as exc:
print(log.PKI_SUBPROCESS_ERROR_1 % exc)
sys.exit(1)
diff --git a/base/server/sbin/pkispawn b/base/server/sbin/pkispawn
index 7d839851f..5892a671f 100755
--- a/base/server/sbin/pkispawn
+++ b/base/server/sbin/pkispawn
@@ -93,7 +93,7 @@ def main(argv):
config.pki_dns_domainname = dnsdomainname
if not len(config.pki_dns_domainname):
print(log.PKI_DNS_DOMAIN_NOT_SET)
- sys.exit(1)
+ config.pki_dns_domainname = config.pki_hostname
except subprocess.CalledProcessError as exc:
print(log.PKI_SUBPROCESS_ERROR_1 % exc)
sys.exit(1)