Bump version numbers for release v0.4.0
[cascardo/ipsilon.git] / contrib / fedora / ipsilon.spec
1 # Bundling request for bootstrap/patternfly: https://fedorahosted.org/fpc/ticket/483
2
3 Name:       ipsilon
4 Version:    0.4.0
5 Release:    1%{?dist}
6 Summary:    An Identity Provider Server
7
8 Group:      System Environment/Base
9 License:    GPLv3+
10 URL:        https://fedorahosted.org/ipsilon/
11 Source0:    https://fedorahosted.org/released/ipsilon/ipsilon-%{version}.tar.gz
12 BuildArch:  noarch
13
14
15 BuildRequires:  python2-devel
16 BuildRequires:  python-setuptools
17 BuildRequires:  lasso-python
18 BuildRequires:  python-openid, python-openid-cla, python-openid-teams
19 BuildRequires:  m2crypto
20 Requires:       httpd
21 Requires:       mod_ssl
22 Requires:       ipsilon-provider = %{version}-%{release}
23 Requires:       mod_wsgi
24 Requires:       python-cherrypy
25 Requires:       python-jinja2
26 Requires:       python-lxml
27 Requires:       python-sqlalchemy
28 Requires:       open-sans-fonts
29 Requires(pre):  shadow-utils
30 Requires(post): %_sbindir/semanage, %_sbindir/restorecon
31 Requires(postun): %_sbindir/semanage
32
33 %description
34 Ipsilon is a multi-protocol Identiy Provider service. Its function is to
35 bridge authentication providers and applications to achieve Single Sign On
36 and Federation.
37
38
39 %package tools
40 Summary:        Client tools for the Ipsilon IDP
41 Group:          System Environment/Base
42 License:        GPLv3+
43 Requires:       python-requests
44 Requires:       python-lxml
45 Requires:       lasso-python
46 Requires:       mod_auth_mellon
47 BuildArch:      noarch
48
49 %description tools
50 Convenience install tools for the Ipsilon identity Provider
51
52
53 %package tools-ipa
54 summary:        IPA helpers
55 Group:          System Environment/Base
56 License:        GPLv3+
57 Requires:       %{name}-tools = %{version}-%{release}
58 %if 0%{?rhel}
59 Requires:       ipa-client
60 Requires:       ipa-admintools
61 %else
62 Requires:       freeipa-client
63 Requires:       freeipa-admintools
64 %endif
65 BuildArch:      noarch
66
67 %description tools-ipa
68 Convenience client install tools for IPA support in the Ipsilon identity Provider
69
70
71 %package saml2
72 Summary:        SAML2 provider plugin
73 Group:          System Environment/Base
74 License:        GPLv3+
75 Provides:       ipsilon-provider = %{version}-%{release}
76 Requires:       %{name} = %{version}-%{release}
77 Requires:       lasso-python
78 BuildArch:      noarch
79
80 %description saml2
81 Provides a SAML2 provider plugin for the Ipsilon identity Provider
82
83
84 %package openid
85 Summary:        Openid provider plugin
86 Group:          System Environment/Base
87 License:        GPLv3+
88 Provides:       ipsilon-provider = %{version}-%{release}
89 Requires:       %{name} = %{version}-%{release}
90 Requires:       python-openid
91 Requires:       python-openid-cla
92 Requires:       python-openid-teams
93 BuildArch:      noarch
94
95 %description openid
96 Provides an OpenId provider plugin for the Ipsilon identity Provider
97
98
99 %package persona
100 Summary:        Persona provider plugin
101 Group:          System Environment/Base
102 License:        GPLv3+
103 Provides:       ipsilon-provider = %{version}-%{release}
104 Requires:       %{name} = %{version}-%{release}
105 Requires:       m2crypto
106 BuildArch:      noarch
107
108 %description persona
109 Provides a Persona provider plugin for the Ipsilon identity Provider
110
111
112 %package authfas
113 Summary:        Fedora Authentication System login plugin
114 Group:          System Environment/Base
115 License:        GPLv3+
116 Requires:       %{name} = %{version}-%{release}
117 Requires:       python-fedora
118 BuildArch:      noarch
119
120 %description authfas
121 Provides a login plugin to authenticate against the Fedora Authentication System
122
123
124 %package authform
125 Summary:        mod_intercept_form_submit login plugin
126 Group:          System Environment/Base
127 License:        GPLv3+
128 Requires:       %{name} = %{version}-%{release}
129 Requires:       mod_intercept_form_submit
130 BuildArch:      noarch
131
132 %description authform
133 Provides a login plugin to authenticate with mod_intercept_form_submit
134
135
136 %package authpam
137 Summary:        PAM based login plugin
138 Group:          System Environment/Base
139 License:        GPLv3+
140 Requires:       %{name} = %{version}-%{release}
141 Requires:       python-pam
142 BuildArch:      noarch
143
144 %description authpam
145 Provides a login plugin to authenticate against the local PAM stack
146
147
148 %package authkrb
149 Summary:        mod_auth_kerb based login plugin
150 Group:          System Environment/Base
151 License:        GPLv3+
152 Requires:       %{name} = %{version}-%{release}
153 Requires:       mod_auth_kerb
154 BuildArch:      noarch
155
156 %description authkrb
157 Provides a login plugin to allow authentication via the mod_auth_kerb Apache
158 module.
159
160
161 %package authldap
162 Summary:        mod_auth_kerb based login plugin
163 Group:          System Environment/Base
164 License:        GPLv3+
165 Requires:       %{name} = %{version}-%{release}
166 Requires:       python-ldap
167 BuildArch:      noarch
168
169 %description authldap
170 Provides a login plugin to allow authentication and info retrieval via LDAP.
171
172 %package infosssd
173 Summary:        SSSD & mod_lookup_identity-based identity plugin
174 Group:          System Environment/Base
175 License:        GPLv3+
176 Requires:       %{name} = %{version}-%{release}
177 Requires:       mod_lookup_identity
178 Requires:       libsss_simpleifp
179 Requires:       sssd >= 1.12.4
180 BuildArch:      noarch
181
182 %description infosssd
183 Provides an info plugin to allow retrieval via mod_lookup_identity and
184 SSSD.
185
186 %prep
187 %setup -q
188
189
190 %build
191 CFLAGS="%{optflags}" %{__python} setup.py build
192
193
194 %install
195 %{__python} setup.py install --skip-build --root %{buildroot}
196 mkdir -p %{buildroot}%{_sbindir}
197 mkdir -p %{buildroot}%{_defaultdocdir}
198 # These 0700 permissions are because ipsilon will store private keys here
199 install -d -m 0700 %{buildroot}%{_sharedstatedir}/ipsilon
200 install -d -m 0700 %{buildroot}%{_sysconfdir}/ipsilon
201 mv %{buildroot}/%{_bindir}/ipsilon %{buildroot}/%{_sbindir}
202 mv %{buildroot}/%{_bindir}/ipsilon-server-install %{buildroot}/%{_sbindir}
203 mv %{buildroot}%{_defaultdocdir}/%{name} %{buildroot}%{_defaultdocdir}/%{name}-%{version}
204 rm -fr %{buildroot}%{python2_sitelib}/tests
205 ln -s %{_datadir}/fonts %{buildroot}%{_datadir}/ipsilon/ui/fonts
206
207 #%check
208 # The test suite is not being run because:
209 #  1. The last step of %%install removes the entire test suite
210 #  2. It increases build time a lot
211 #  3. It adds more build dependencies (namely postgresql server and client libraries)
212
213 %pre
214 getent group ipsilon >/dev/null || groupadd -r ipsilon
215 getent passwd ipsilon >/dev/null || \
216     useradd -r -g ipsilon -d %{_sharedstatedir}/ipsilon -s /sbin/nologin \
217     -c "Ipsilon Server" ipsilon
218 exit 0
219
220 %post
221 semanage fcontext -a -t httpd_var_lib_t '%{_sharedstatedir}/ipsilon(/.*)?' || :
222 semanage fcontext -a -t var_lib_t '%{_sharedstatedir}/ipsilon(/.*)/*.conf' || :
223 restorecon -R %{_sharedstatedir}/ipsilon || :
224
225 %postun
226 # Clean up after package removal
227 if [ $1 -eq 0 ]; then
228     semanage fcontext -d -t var_lib_t '%{_sharedstatedir}/ipsilon(/.*)/*.conf' || :
229     semanage fcontext -d -t httpd_var_lib_t '%{_sharedstatedir}/ipsilon(/.*)?' || :
230 fi
231
232
233 %files
234 %{_defaultdocdir}/%{name}-%{version}
235 %{python2_sitelib}/ipsilon/__init__.py*
236 %{python2_sitelib}/ipsilon-*.egg-info
237 %dir %{python2_sitelib}/ipsilon
238 %{python2_sitelib}/ipsilon/admin
239 %dir %{python2_sitelib}/ipsilon/login
240 %{python2_sitelib}/ipsilon/login/__init__*
241 %{python2_sitelib}/ipsilon/login/common*
242 %{python2_sitelib}/ipsilon/login/authtest*
243 %dir %{python2_sitelib}/ipsilon/info
244 %{python2_sitelib}/ipsilon/info/__init__*
245 %{python2_sitelib}/ipsilon/info/common*
246 %{python2_sitelib}/ipsilon/info/nss*
247 %dir %{python2_sitelib}/ipsilon/providers
248 %{python2_sitelib}/ipsilon/providers/__init__*
249 %{python2_sitelib}/ipsilon/providers/common*
250 %{python2_sitelib}/ipsilon/root.py*
251 %{python2_sitelib}/ipsilon/util
252 %{_mandir}/man*/ipsilon*
253 %dir %{_datadir}/ipsilon
254 %dir %{_datadir}/ipsilon/templates
255 %{_datadir}/ipsilon/templates/*.html
256 %{_datadir}/ipsilon/templates/admin
257 %dir %{_datadir}/ipsilon/templates/login
258 %{_datadir}/ipsilon/templates/login/index.html
259 %{_datadir}/ipsilon/templates/login/form.html
260 %dir %{_datadir}/ipsilon/ui
261 %dir %{python2_sitelib}/ipsilon/tools
262 %{python2_sitelib}/ipsilon/tools/__init__.py*
263 %{python2_sitelib}/ipsilon/tools/files.py*
264 %{_datadir}/ipsilon/ui/css
265 %{_datadir}/ipsilon/ui/img
266 %{_datadir}/ipsilon/ui/js
267 %{_datadir}/ipsilon/ui/fonts
268 %{_sbindir}/ipsilon
269 %dir %attr(0700,ipsilon,ipsilon) %{_sharedstatedir}/ipsilon
270 %dir %attr(0700,ipsilon,ipsilon) %{_sysconfdir}/ipsilon
271
272 %files tools
273 %doc COPYING README
274 %dir %{python2_sitelib}/ipsilon/helpers
275 %{python2_sitelib}/ipsilon/helpers/common.py*
276 %{python2_sitelib}/ipsilon/helpers/__init__.py*
277 %{_datadir}/ipsilon/templates/install/saml2
278 %{_datadir}/ipsilon/ui/saml2sp
279 %{_bindir}/ipsilon-client-install
280 %{_sbindir}/ipsilon-server-install
281 %dir %{_datadir}/ipsilon/templates/install
282 %{_datadir}/ipsilon/templates/install/*.conf
283
284 %files tools-ipa
285 %{python2_sitelib}/ipsilon/helpers/ipa.py*
286
287 %files saml2
288 %{python2_sitelib}/ipsilon/tools/certs.py*
289 %{python2_sitelib}/ipsilon/tools/saml2metadata.py*
290 %{python2_sitelib}/ipsilon/providers/saml2*
291 %{_datadir}/ipsilon/templates/saml2
292
293 %files openid
294 %{python2_sitelib}/ipsilon/providers/openid*
295 %{_datadir}/ipsilon/templates/openid
296
297 %files persona
298 %{python2_sitelib}/ipsilon/providers/persona*
299 %{_datadir}/ipsilon/templates/persona
300
301 %files authfas
302 %{python2_sitelib}/ipsilon/login/authfas*
303
304 %files authform
305 %{python2_sitelib}/ipsilon/login/authform*
306
307 %files authpam
308 %{python2_sitelib}/ipsilon/login/authpam*
309
310 %files authkrb
311 %{python2_sitelib}/ipsilon/login/authkrb*
312 %{_datadir}/ipsilon/templates/login/krb.html
313
314 %files authldap
315 %{python2_sitelib}/ipsilon/login/authldap*
316 %{python2_sitelib}/ipsilon/info/infoldap*
317
318 %files infosssd
319 %{python2_sitelib}/ipsilon/info/infosssd.*
320
321 %changelog
322 * Fri Feb 27 2015 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.4.0-1
323 - Released 0.4.0
324
325 * Tue Feb 24 2015 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.3.0-7
326 - Split the installer into -tools
327 - Split authform into -authform
328
329 * Thu Feb 12 2015 Rob Crittenden <rcritten@redhat.com> - 0.3.0-6
330 - Add mod_identity_lookup info plugin package
331
332 * Wed Jan 28 2015 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.3.0-5
333 - Split IPA tools
334
335 * Mon Jan 12 2015 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.3.0-4
336 - Add symlink to fonts directory
337
338 * Tue Dec 16 2014 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.3.0-3
339 - Fix typo
340 - Add comments on why the test suite is not in check
341 - The subpackages require the base package
342 - Add link to FPC ticket for bundling exception request
343
344 * Tue Dec 16 2014 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.3.0-2
345 - Fix shebang removal
346
347 * Tue Dec 16 2014 Patrick Uiterwijk <puiterwijk@redhat.com> - 0.3.0-1
348 - Initial packaging