mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-22 23:23:30 -06:00
Generate /etc/httpd/conf.d/ipa.conf from a template so the realm can
be set during installation
This commit is contained in:
parent
993f76fe60
commit
b9b06a2a60
@ -12,8 +12,6 @@ BuildArch: noarch
|
||||
|
||||
Requires: python fedora-ds-base krb5-server krb5-server-ldap nss-tools openldap-clients httpd mod_python mod_auth_kerb python-ldap freeipa-python cyrus-sasl-gssapi
|
||||
|
||||
%define httpd_conf /etc/httpd/conf.d
|
||||
|
||||
%description
|
||||
FreeIPA is a server for identity, policy, and audit.
|
||||
|
||||
@ -23,7 +21,6 @@ FreeIPA is a server for identity, policy, and audit.
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
mkdir -p %{buildroot}%{_sbindir}
|
||||
mkdir -p %{buildroot}%{httpd_conf}
|
||||
|
||||
make install DESTDIR=%{buildroot}
|
||||
|
||||
@ -40,8 +37,6 @@ rm -rf %{buildroot}
|
||||
%dir %{_usr}/share/ipa
|
||||
%{_usr}/share/ipa/*
|
||||
|
||||
%{httpd_conf}/ipa.conf
|
||||
|
||||
|
||||
%changelog
|
||||
* Mon Aug 5 2007 Rob Crittenden <rcritten@redhat.com> - 0.1.0-3
|
||||
|
@ -12,8 +12,6 @@ BuildArch: noarch
|
||||
|
||||
Requires: python fedora-ds-base krb5-server krb5-server-ldap nss-tools openldap-clients httpd mod_python mod_auth_kerb python-ldap freeipa-python cyrus-sasl-gssapi
|
||||
|
||||
%define httpd_conf /etc/httpd/conf.d
|
||||
|
||||
%description
|
||||
FreeIPA is a server for identity, policy, and audit.
|
||||
|
||||
@ -23,7 +21,6 @@ FreeIPA is a server for identity, policy, and audit.
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
mkdir -p %{buildroot}%{_sbindir}
|
||||
mkdir -p %{buildroot}%{httpd_conf}
|
||||
|
||||
make install DESTDIR=%{buildroot}
|
||||
|
||||
@ -40,8 +37,6 @@ rm -rf %{buildroot}
|
||||
%dir %{_usr}/share/ipa
|
||||
%{_usr}/share/ipa/*
|
||||
|
||||
%{httpd_conf}/ipa.conf
|
||||
|
||||
|
||||
%changelog
|
||||
* Mon Aug 5 2007 Rob Crittenden <rcritten@redhat.com> - 0.1.0-3
|
||||
|
@ -79,6 +79,8 @@ class KrbInstance:
|
||||
|
||||
self.__configure_ldap()
|
||||
|
||||
self.__configure_http()
|
||||
|
||||
self.__create_instance()
|
||||
|
||||
self.__create_ds_keytab()
|
||||
@ -193,3 +195,9 @@ class KrbInstance:
|
||||
time.sleep(1)
|
||||
pent = pwd.getpwnam("apache")
|
||||
os.chown("/etc/httpd/conf/ipa.keytab", pent.pw_uid, pent.pw_gid)
|
||||
|
||||
def __configure_http(self):
|
||||
http_txt = template_file(SHARE_DIR + "ipa.conf", self.sub_dict)
|
||||
http_fd = open("/etc/httpd/conf.d/ipa.conf", "w")
|
||||
http_fd.write(http_txt)
|
||||
http_fd.close()
|
||||
|
@ -1,12 +1,11 @@
|
||||
SHAREDIR = $(DESTDIR)/usr/share/ipa/ipaserver
|
||||
HTTPDIR = $(DESTDIR)/etc/httpd/conf.d/
|
||||
|
||||
all: ;
|
||||
|
||||
install:
|
||||
-mkdir -p $(SHAREDIR)
|
||||
install -m 644 *.py $(SHAREDIR)
|
||||
install -m 644 ipa.conf $(HTTPDIR)
|
||||
install -m 644 ipa.conf $(SHAREDIR)/..
|
||||
|
||||
clean:
|
||||
rm -f *~ *.pyc
|
||||
|
@ -8,7 +8,7 @@ Alias /ipa "/usr/share/ipa/ipaserver/XMLRPC"
|
||||
KrbMethodNegotiate on
|
||||
KrbMethodK5Passwd off
|
||||
KrbServiceName HTTP
|
||||
KrbAuthRealms GREYOAK.COM
|
||||
KrbAuthRealms $REALM
|
||||
Krb5KeyTab /etc/httpd/conf/ipa.keytab
|
||||
KrbSaveCredentials on
|
||||
Require valid-user
|
||||
|
Loading…
Reference in New Issue
Block a user