diff options
| author | Michael DeHaan <mdehaan@redhat.com> | 2008-01-29 17:08:45 -0500 |
|---|---|---|
| committer | Michael DeHaan <mdehaan@redhat.com> | 2008-01-29 17:08:45 -0500 |
| commit | cd30007bc66ab5b0512e94c94c84de5e95e8e3ad (patch) | |
| tree | 68d2f792cfb7c3e6410019116209578e45dd5b33 /func/certmaster.py | |
| parent | 6c47e982fa3089f86ce96742b0673dc320ac208e (diff) | |
Applying a variant on Brenton's patch for DNS issues.
Diffstat (limited to 'func/certmaster.py')
| -rwxr-xr-x | func/certmaster.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/func/certmaster.py b/func/certmaster.py index 1cde806..fdb34b8 100755 --- a/func/certmaster.py +++ b/func/certmaster.py @@ -36,7 +36,15 @@ CERTMASTER_LISTEN_PORT = 51235 class CertMaster(object): def __init__(self, conf_file): self.cfg = read_config(conf_file, CMConfig) - mycn = '%s-CA-KEY' % socket.getfqdn() + + fqdn = socket.getfqdn() + host = socket.gethostname() + if fdqn.find(host) != -1: + usename = fqdn + else: + usename = host + + mycn = '%s-CA-KEY' % usename self.ca_key_file = '%s/funcmaster.key' % self.cfg.cadir self.ca_cert_file = '%s/funcmaster.crt' % self.cfg.cadir try: |
