mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Use Dogtag 10 only when it is available
Put the changes from Ade's dogtag 10 patch into namespaced constants in dogtag.py, which are then referenced in the code. Make ipaserver.install.CAInstance use the service name specified in the configuration. Uninstallation, where config is removed before CA uninstall, also uses the (previously) configured value. This and Ade's patch address https://fedorahosted.org/freeipa/ticket/2846
This commit is contained in:
committed by
Rob Crittenden
parent
3dd31a8756
commit
4f76c143d2
@@ -29,6 +29,7 @@ try:
|
||||
from ipapython.config import IPAOptionParser
|
||||
from ipapython.ipa_log_manager import *
|
||||
from ipapython import certmonger
|
||||
from ipapython import dogtag
|
||||
from ipaserver.install import installutils
|
||||
from ipaserver.install import dsinstance
|
||||
from ipaserver.install import httpinstance
|
||||
@@ -458,7 +459,7 @@ def enable_certificate_renewal(realm):
|
||||
ca.configure_agent_renewal()
|
||||
ca.track_servercert()
|
||||
sysupgrade.set_upgrade_state('dogtag', 'renewal_configured', True)
|
||||
ca.restart(cainstance.PKI_INSTANCE_NAME)
|
||||
ca.restart(dogtag.configured_constants().PKI_INSTANCE_NAME)
|
||||
root_logger.debug('CA subsystem certificate renewal enabled')
|
||||
|
||||
def main():
|
||||
@@ -495,7 +496,14 @@ def main():
|
||||
check_certs()
|
||||
|
||||
auto_redirect = find_autoredirect(fqdn)
|
||||
sub_dict = { "REALM" : api.env.realm, "FQDN": fqdn, "AUTOREDIR": '' if auto_redirect else '#'}
|
||||
configured_constants = dogtag.configured_constants()
|
||||
sub_dict = dict(
|
||||
REALM=api.env.realm,
|
||||
FQDN=fqdn,
|
||||
AUTOREDIR='' if auto_redirect else '#',
|
||||
CRL_PUBLISH_PATH=configured_constants.CRL_PUBLISH_PATH,
|
||||
DOGTAG_PORT=configured_constants.AJP_PORT,
|
||||
)
|
||||
|
||||
upgrade(sub_dict, "/etc/httpd/conf.d/ipa.conf", ipautil.SHARE_DIR + "ipa.conf")
|
||||
upgrade(sub_dict, "/etc/httpd/conf.d/ipa-rewrite.conf", ipautil.SHARE_DIR + "ipa-rewrite.conf")
|
||||
|
||||
Reference in New Issue
Block a user