diff options
author | Rob Crittenden <rcritten@redhat.com> | 2010-05-28 11:19:45 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2010-06-01 09:53:10 -0400 |
commit | 3f5b4233cbf72b25ea86c4c15528200136d14c7a (patch) | |
tree | 4bad765162ee821c302f4a806106313d3828f062 | |
parent | af49945ae4d6cc9ed44f5b9ebfafe8f05b7f8459 (diff) | |
download | freeipa-3f5b4233cbf72b25ea86c4c15528200136d14c7a.tar.gz freeipa-3f5b4233cbf72b25ea86c4c15528200136d14c7a.tar.xz freeipa-3f5b4233cbf72b25ea86c4c15528200136d14c7a.zip |
Catch the condition where dogtag is already configured (no preop.pin)
This causes the installation to blow up badly otherwise.
To remove an existing instance run:
# pkiremove -pki_instance_root=/var/lib -pki_instance_name=pki-ca
-rw-r--r-- | ipaserver/install/cainstance.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ipaserver/install/cainstance.py b/ipaserver/install/cainstance.py index 11e896ba1..90028b41d 100644 --- a/ipaserver/install/cainstance.py +++ b/ipaserver/install/cainstance.py @@ -113,6 +113,9 @@ def get_preop_pin(instance_root, instance_name): preop_pin=match.group(1) break + if preop_pin is None: + raise RuntimeError("Unable to find preop.pin in %s. Is your CA already configured?" % filename) + return preop_pin def import_pkcs12(input_file, input_passwd, cert_database, |