1 %global with_doc %{!?_without_doc:1}%{?_without_doc:0}
7 Summary: OpenStack Volume service
9 Group: Applications/System
11 URL: http://www.openstack.org/software/openstack-storage/
12 Source0: cinder-%{version}.tar.gz
13 Source1: cinder-dist.conf
14 Source2: cinder.logrotate
15 Source3: cinder-tgt.conf
17 Source10: openstack-cinder-api.service
18 Source11: openstack-cinder-scheduler.service
19 Source12: openstack-cinder-volume.service
20 Source13: openstack-cinder-backup.service
21 Source20: cinder-sudoers
24 BuildRequires: intltool
25 BuildRequires: python-oslo-sphinx >= 2.5.0
26 BuildRequires: python-pbr >= 1.6
27 BuildRequires: python-sphinx >= 1.1.2
28 BuildRequires: python-setuptools
29 BuildRequires: python-stevedore >= 1.10.0
30 # Required to build cinder.conf
31 BuildRequires: python-glanceclient >= 1:2.0.0
32 BuildRequires: python-google-api-client >= 1.4.2
33 BuildRequires: python-httplib2 >= 0.7.5
34 BuildRequires: python-keystoneclient >= 1:1.7.0
35 BuildRequires: python-keystonemiddleware >= 4.0.0
36 BuildRequires: python-lxml >= 2.3
37 BuildRequires: python-novaclient >= 1:2.29.0
38 BuildRequires: python-oslo-concurrency >= 3.8.0
39 BuildRequires: python-oslo-config >= 2:3.10.0
40 BuildRequires: python-oslo-context >= 2.4.0
41 BuildRequires: python-oslo-db >= 4.1.0
42 BuildRequires: python-oslo-i18n >= 2.1.0
43 BuildRequires: python-oslo-log >= 1.14.0
44 BuildRequires: python-oslo-messaging >= 5.2.0
45 BuildRequires: python-oslo-middleware >= 3.0.0
46 BuildRequires: python-oslo-policy >= 1.9.0
47 BuildRequires: python-oslo-reports >= 0.6.0
48 BuildRequires: python-oslo-rootwrap >= 2.0.0
49 BuildRequires: python-oslo-serialization >= 1.10.0
50 BuildRequires: python-oslo-service >= 1.10.0
51 BuildRequires: python-oslo-utils >= 3.11.0
52 BuildRequires: python-oslo-versionedobjects >= 1.9.1
53 BuildRequires: python-oslo-vmware >= 1.16.0
54 BuildRequires: python-paramiko >= 2.0.0
55 BuildRequires: python-paste
56 BuildRequires: python-suds-jurko >= 0.6
57 BuildRequires: python-swiftclient >= 2.2.0
58 BuildRequires: python-taskflow >= 1.26.0
59 BuildRequires: python-tooz >= 1.28.0
60 BuildRequires: python-webob >= 1.2.3
61 BuildRequires: python2-os-win >= 0.2.3
63 BuildRequires: python-os-brick >= 1.3.0
65 Requires: python-cinder = %{epoch}:%{version}-%{release}
67 Requires: python-pbr >= 1.6
70 Requires: python-cinderclient
72 Requires(post): systemd
73 Requires(preun): systemd
74 Requires(postun): systemd
75 Requires(pre): shadow-utils
78 Requires: python-osprofiler >= 1.3.0
79 Requires: python-rtslib >= 2.1.fb41
82 OpenStack Volume (codename Cinder) provides services to manage and
83 access block storage volumes for use by Virtual Machine instances.
86 %package -n python-cinder
87 Summary: OpenStack Volume Python libraries
88 Group: Applications/System
94 Requires: python-os-brick >= 1.3.0
95 Requires: python-paramiko >= 2.0.0
98 Requires: python-kombu >= 3.0.7
99 Requires: python-amqplib
101 Requires: python-eventlet >= 0.18.2
102 Requires: python-greenlet >= 0.3.2
103 Requires: python-iso8601 >= 0.1.11
104 Requires: python-lxml >= 2.3
105 Requires: python-stevedore >= 1.10.0
106 Requires: python-suds-jurko >= 0.6
107 Requires: python-tooz >= 1.28.0
109 Requires: python-sqlalchemy >= 1.0.10
110 Requires: python-migrate >= 0.9.6
112 Requires: python-paste-deploy >= 1.5.0
113 Requires: python-routes >= 1.12.3
114 Requires: python-webob >= 1.2.3
116 Requires: python-glanceclient >= 1:2.0.0
117 Requires: python-swiftclient >= 2.2.0
118 Requires: python-keystoneclient >= 1:1.7.0
119 Requires: python-novaclient >= 1:2.29.0
121 Requires: python-oslo-config >= 2:3.10.0
122 Requires: python-six >= 1.9.0
124 Requires: python-babel >= 2.3.4
125 Requires: python-google-api-client >= 1.4.2
127 Requires: python-oslo-rootwrap >= 2.0.0
128 Requires: python-oslo-utils >= 3.11.0
129 Requires: python-oslo-serialization >= 1.10.0
130 Requires: python-oslo-db >= 4.1.0
131 Requires: python-oslo-context >= 2.4.0
132 Requires: python-oslo-concurrency >= 3.8.0
133 Requires: python-oslo-middleware >= 3.0.0
134 Requires: python-taskflow >= 1.26.0
135 Requires: python-oslo-messaging >= 5.2.0
136 Requires: python-oslo-policy >= 1.9.0
137 Requires: python-oslo-reports >= 0.6.0
138 Requires: python-oslo-service >= 1.10.0
139 Requires: python-oslo-versionedobjects >= 1.9.1
141 Requires: iscsi-initiator-utils
143 Requires: python-osprofiler >= 1.3.0
144 Requires: python-ipaddress >= 1.0.7
145 Requires: MySQL-python
146 Requires: pyparsing >= 2.0.3
147 Requires: python-barbicanclient >= 4.0.0
148 Requires: python-crypto >= 2.6
149 Requires: python-decorator >= 3.4.0
150 Requires: python-enum34
151 Requires: python-httplib2 >= 0.7.5
152 Requires: python-keystonemiddleware >= 4.0.0
153 Requires: python-oauth2client >= 1.5.0
154 Requires: python-oslo-i18n >= 2.1.0
155 Requires: python-oslo-log >= 1.14.0
156 Requires: python-oslo-vmware >= 1.16.0
157 Requires: python-paste
158 Requires: python-pbr >= 1.6
159 Requires: python-requests >= 2.10.0
160 Requires: python-retrying >= 1.2.3
161 Requires: python-rtslib >= 2.1.fb41
162 Requires: python-simplejson >= 2.2.0
163 Requires: python2-os-win >= 0.2.3
164 Requires: pytz >= 2013.6
167 %description -n python-cinder
168 OpenStack Volume (codename Cinder) provides services to manage and
169 access block storage volumes for use by Virtual Machine instances.
171 This package contains the cinder Python library.
175 Summary: Documentation for OpenStack Volume
178 Requires: %{name} = %{epoch}:%{version}-%{release}
180 BuildRequires: graphviz
182 # Required to build module documents
183 BuildRequires: python-eventlet >= 0.18.2
184 BuildRequires: python-routes >= 1.12.3
185 BuildRequires: python-sqlalchemy >= 1.0.10
186 BuildRequires: python-webob >= 1.2.3
187 # while not strictly required, quiets the build down when building docs.
188 BuildRequires: python-migrate >= 0.9.6
189 BuildRequires: python-iso8601 >= 0.1.11
192 OpenStack Volume (codename Cinder) provides services to manage and
193 access block storage volumes for use by Virtual Machine instances.
195 This package contains documentation files for cinder.
199 %setup -q -n cinder-%{version}
202 find . \( -name .gitignore -o -name .placeholder \) -delete
204 find cinder -name \*.py -exec sed -i '/\/usr\/bin\/env python/{d;q}' {} +
206 # Remove the requirements file so that pbr hooks don't add it
207 # to distutils requires_dist config
208 rm -rf {test-,}requirements.txt tools/{pip,test}-requires
211 %{__python2} setup.py build
212 # docs generation requires everything to be installed first
213 export PYTHONPATH="$( pwd ):$PYTHONPATH"
218 SPHINX_DEBUG=1 sphinx-build -b html source build/html
219 # Fix hidden-file-or-dir warnings
220 rm -fr build/html/.doctrees build/html/.buildinfo
223 # Create dir link to avoid a sphinx-build exception
224 mkdir -p build/man/.doctrees/
225 ln -s . build/man/.doctrees/man
229 SPHINX_DEBUG=1 sphinx-build -b man -c . man ../build/man
234 # Generate configuration files
235 oslo-config-generator --config-file=cinder/config/cinder-config-generator.conf --output-file etc/cinder/cinder.conf.sample
238 %{__python2} setup.py install -O1 --skip-build --root %{buildroot}
240 mkdir -p %{buildroot}%{_mandir}/man1
241 install -p -D -m 644 doc/build/man/*.1 %{buildroot}%{_mandir}/man1/
244 install -d -m 755 %{buildroot}%{_sharedstatedir}/cinder
245 install -d -m 755 %{buildroot}%{_sharedstatedir}/cinder/tmp
246 install -d -m 755 %{buildroot}%{_localstatedir}/log/cinder
248 # Install config files
249 install -d -m 755 %{buildroot}%{_sysconfdir}/cinder
250 install -p -D -m 640 %{SOURCE1} %{buildroot}%{_datadir}/cinder/cinder-dist.conf
251 install -d -m 755 %{buildroot}%{_sysconfdir}/cinder/volumes
252 install -p -D -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/tgt/conf.d/cinder.conf
253 install -p -D -m 640 etc/cinder/rootwrap.conf %{buildroot}%{_sysconfdir}/cinder/rootwrap.conf
254 install -p -D -m 640 etc/cinder/api-paste.ini %{buildroot}%{_sysconfdir}/cinder/api-paste.ini
255 install -p -D -m 640 etc/cinder/policy.json %{buildroot}%{_sysconfdir}/cinder/policy.json
256 install -p -D -m 640 etc/cinder/cinder.conf.sample %{buildroot}%{_sysconfdir}/cinder/cinder.conf
258 # Install initscripts for services
259 install -p -D -m 644 %{SOURCE10} %{buildroot}%{_unitdir}/openstack-cinder-api.service
260 install -p -D -m 644 %{SOURCE11} %{buildroot}%{_unitdir}/openstack-cinder-scheduler.service
261 install -p -D -m 644 %{SOURCE12} %{buildroot}%{_unitdir}/openstack-cinder-volume.service
262 install -p -D -m 644 %{SOURCE13} %{buildroot}%{_unitdir}/openstack-cinder-backup.service
265 install -p -D -m 440 %{SOURCE20} %{buildroot}%{_sysconfdir}/sudoers.d/cinder
268 install -p -D -m 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/logrotate.d/openstack-cinder
270 # Install pid directory
271 install -d -m 755 %{buildroot}%{_localstatedir}/run/cinder
273 # Install rootwrap files in /usr/share/cinder/rootwrap
274 mkdir -p %{buildroot}%{_datarootdir}/cinder/rootwrap/
275 install -p -D -m 644 etc/cinder/rootwrap.d/* %{buildroot}%{_datarootdir}/cinder/rootwrap/
278 # Symlinks to rootwrap config files
279 mkdir -p %{buildroot}%{_sysconfdir}/cinder/rootwrap.d
280 for filter in %{_datarootdir}/os-brick/rootwrap/*.filters; do
281 ln -s $filter %{buildroot}%{_sysconfdir}/cinder/rootwrap.d/
283 # Remove unneeded in production stuff
284 rm -f %{buildroot}%{_bindir}/cinder-all
285 rm -f %{buildroot}%{_bindir}/cinder-debug
286 rm -fr %{buildroot}%{python2_sitelib}/cinder/tests/
287 rm -fr %{buildroot}%{python2_sitelib}/run_tests.*
288 rm -f %{buildroot}/usr/share/doc/cinder/README*
291 getent group cinder >/dev/null || groupadd -r cinder --gid 165
292 if ! getent passwd cinder >/dev/null; then
293 useradd -u 165 -r -g cinder -G cinder,nobody -d %{_sharedstatedir}/cinder -s /sbin/nologin -c "OpenStack Cinder Daemons" cinder
298 %systemd_post openstack-cinder-volume
299 %systemd_post openstack-cinder-api
300 %systemd_post openstack-cinder-scheduler
301 %systemd_post openstack-cinder-backup
304 %systemd_preun openstack-cinder-volume
305 %systemd_preun openstack-cinder-api
306 %systemd_preun openstack-cinder-scheduler
307 %systemd_preun openstack-cinder-backup
310 %systemd_postun_with_restart openstack-cinder-volume
311 %systemd_postun_with_restart openstack-cinder-api
312 %systemd_postun_with_restart openstack-cinder-scheduler
313 %systemd_postun_with_restart openstack-cinder-backup
317 %dir %{_sysconfdir}/cinder
318 %config(noreplace) %attr(-, root, cinder) %{_sysconfdir}/cinder/cinder.conf
319 %config(noreplace) %attr(-, root, cinder) %{_sysconfdir}/cinder/api-paste.ini
320 %config(noreplace) %attr(-, root, cinder) %{_sysconfdir}/cinder/rootwrap.conf
321 %config(noreplace) %attr(-, root, cinder) %{_sysconfdir}/cinder/policy.json
322 %config(noreplace) %{_sysconfdir}/logrotate.d/openstack-cinder
323 %config(noreplace) %{_sysconfdir}/sudoers.d/cinder
324 %config(noreplace) %{_sysconfdir}/tgt/conf.d/cinder.conf
325 %{_sysconfdir}/cinder/rootwrap.d/
326 %attr(-, root, cinder) %{_datadir}/cinder/cinder-dist.conf
328 %dir %attr(0750, cinder, root) %{_localstatedir}/log/cinder
329 %dir %attr(0755, cinder, root) %{_localstatedir}/run/cinder
330 %dir %attr(0755, cinder, root) %{_sysconfdir}/cinder/volumes
333 %{_unitdir}/*.service
334 %{_datarootdir}/cinder
335 %{_mandir}/man1/cinder*.1.gz
337 %defattr(-, cinder, cinder, -)
338 %dir %{_sharedstatedir}/cinder
339 %dir %{_sharedstatedir}/cinder/tmp
341 %files -n python-cinder
342 %{?!_licensedir: %global license %%doc}
344 %{python2_sitelib}/cinder
345 %{python2_sitelib}/cinder-*.egg-info
353 * Tue Jun 28 2016 Mikhail Ivanov <mivanov@mirantis.com> - 9.0.0~b1
354 - Update to 9.0.0.0b1
355 - Update build and runtime dependencies
357 * Wed Mar 09 2016 Alexander Tsamutali <atsamutali@mirantis.com> - 8.0.0.0b2-1
358 - Update to 8.0.0.0b3.
359 - Sync with RDO spec.
361 * Mon Sep 28 2015 Mikhail Ivanov <mivanov@mirantis.com> - 7.0.0.0rc1-1~mos8.0.1
362 - Update to a new upstream version
363 - Update build and runtime dependencies
365 * Wed Jun 11 2014 Eric Harney <eharney@redhat.com> - 2014.1.1-2
366 - Add dependency on iscsi-initiator-utils
368 * Mon Jun 09 2014 Eric Harney <eharney@redhat.com> - 2014.1.1-1
369 - Update to Icehouse stable release 1
371 * Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2014.1-4
372 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
374 * Tue Apr 29 2014 Alan Pevec <apevec@redhat.com> - 2014.1-3
375 - drop crudini build dependency
377 * Mon Apr 21 2014 Eric Harney <eharney@redhat.com> - 2014.1-2
378 - Remove qpid settings from cinder-dist.conf
380 * Thu Apr 17 2014 Eric Harney <eharney@redhat.com> - 2014.1-1
381 - Update to 2014.1 (Icehouse)
383 * Tue Apr 15 2014 Eric Harney <eharney@redhat.com> - 2014.1-0.10.rc3
384 - Add python-oslo-messaging requirement
385 - Add GlusterFS delete patch
386 - Add systemd patches (not used yet)
388 * Tue Apr 15 2014 Eric Harney <eharney@redhat.com> - 2014.1-0.9.rc3
389 - Update to Icehouse RC3
391 * Mon Apr 07 2014 Eric Harney <eharney@redhat.com> - 2014.1-0.8.rc2
392 - Update to Icehouse RC2
393 - Icehouse requires newer version of python-six
395 * Thu Mar 27 2014 Eric Harney <eharney@redhat.com> - 2014.1-0.7.rc1
396 - Update to Icehouse RC1
398 * Tue Mar 25 2014 Pádraig Brady <pbrady@redhat.com> - 2014.1-0.6.b3
399 - Depend on python-rtslib and targetcli rather than scsi-target-utils
401 * Fri Mar 21 2014 Pádraig Brady <pbrady@redhat.com> - 2014.1-0.5.b3
402 - Use lioadm iSCSI helper rather than tgtadm
404 * Sun Mar 16 2014 Eric Harney <eharney@redhat.com> - 2014.1-0.4.b3
405 - Update to Icehouse milestone 3
406 - Add deps on python-oslo-rootwrap, python-taskflow
408 * Mon Jan 27 2014 Eric Harney <eharney@redhat.com> - 2014.1-0.3.b2
409 - Update to Icehouse milestone 2
411 * Mon Jan 06 2014 Pádraig Brady <pbrady@redhat.com> - 2014.1-0.2.b1
412 - Set python-six min version to ensure updated
414 * Thu Dec 19 2013 Eric Harney <eharney@redhat.com> - 2014.1-0.1.b1
415 - Update to Icehouse milestone 1
417 * Mon Oct 28 2013 Eric Harney <eharney@redhat.com> - 2013.2-2
418 - Fix GlusterFS volume driver clone operations
420 * Thu Oct 17 2013 Eric Harney <eharney@redhat.com> - 2013.2-1
421 - Update to 2013.2 (Havana)
422 - Restart/remove cinder-backup service during upgrade/uninstallation
424 * Wed Oct 16 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.13.rc3
425 - Update to Havana RC3
427 * Fri Oct 11 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.12.rc2
428 - Update to Havana RC2
430 * Tue Oct 08 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.11.rc1
431 - Update to Havana RC1
432 - Fix python-novaclient req epoch
434 * Mon Sep 23 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.10.b3
435 - Depend on python-novaclient 2.15
437 * Wed Sep 18 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.9.b3
438 - Add cinder-dist.conf
439 - Tighten permissions on /var/log/cinder
441 * Mon Sep 9 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.8.b3
442 - Update to Havana milestone 3
443 - Add dependency on python-novaclient
445 * Thu Aug 29 2013 Pádraig Brady <pbrady@redhat.com> - 2013.2-0.7.b2
446 - Add dependency on sysfsutils to support the fiber channel driver
448 * Mon Aug 26 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.6.b2
449 - Add cinder-backup service init script
451 * Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2013.2-0.5.b2
452 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
454 * Mon Jul 22 2013 Pádraig Brady <pbrady@redhat.com> - 2013.2-0.4.b2
455 - Add dependency on python-suds to support the netapp driver
456 - Add dependency on python-keystoneclient for auth token middleware
457 - Add dependency on qemu-img for volume creation from Glance images
459 * Sun Jul 21 2013 Pádraig Brady <pbrady@redhat.com> - 2013.2-0.3.b2
460 - Update to Havana milestone 2
462 * Thu Jun 13 2013 Eric Harney <eharney@redhat.com> - 2013.2-0.2.b1
463 - Update to Havana milestone 1
465 * Mon May 13 2013 Eric Harney <eharney@redhat.com> - 2013.1.1-1
466 - Update to Grizzly stable release 1, 2013.1.1
468 * Mon Apr 08 2013 Eric Harney <eharney@redhat.com> - 2013.1-2
469 - Backport fix for GlusterFS driver get_volume_stats
471 * Thu Apr 04 2013 Eric Harney <eharney@redhat.com> - 2013.1-1
472 - Update to Grizzly final release
474 * Tue Apr 2 2013 Pádraig Brady <pbrady@redhat.com> - 2013.1-0.6.rc3
475 - Adjust to support sqlalchemy-0.8.0
477 * Wed Mar 27 2013 Eric Harney <eharney@redhat.com> - 2013.1-0.5.rc3
478 - Update to Grizzly RC3 release
480 * Mon Mar 25 2013 Eric Harney <eharney@redhat.com> - 2013.1-0.5.rc2
481 - Update to Grizzly RC2 release
483 * Mon Mar 18 2013 Eric Harney <eharney@redhat.com> - 2013.1-0.5.rc1
484 - Update to Grizzly RC1 release
486 * Tue Mar 05 2013 Pádraig Brady <P@draigBrady.com> - 2013.1-0.4.g3
487 - Add dependency on python-stevedore
489 * Mon Feb 25 2013 Eric Harney <eharney@redhat.com> - 2013.1-0.3.g3
490 - Fix build issues with G-3 update
492 * Mon Feb 25 2013 Eric Harney <eharney@redhat.com> - 2013.1-0.2.g3
493 - Update to Grizzly milestone 3
495 * Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2013.1-0.2.g2
496 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
498 * Thu Jan 10 2013 Eric Harney <eharney@redhat.com> - 2013.1-0.1.g2
499 - Update to Grizzly milestone 2
501 * Thu Nov 29 2012 Eric Harney <eharney@redhat.com> - 2013.1-0.1.g1
502 - Update to Grizzly milestone 1
504 * Wed Nov 14 2012 Eric Harney <eharney@redhat.com> - 2012.2-2
505 - Remove unused dependency on python-daemon
507 * Thu Sep 27 2012 Pádraig Brady <P@draigBrady.com> - 2012.2-1
508 - Update to Folsom final
510 * Fri Sep 21 2012 Pádraig Brady <P@draigBrady.com> - 2012.2-0.5.rc1
511 - Update to Folsom RC1
513 * Fri Sep 21 2012 Pádraig Brady <P@draigBrady.com> - 2012.2-0.4.f3
514 - Fix to ensure that tgt configuration is honored
516 * Mon Sep 17 2012 Pádraig Brady <P@draigBrady.com> - 2012.2-0.3.f3
517 - Move user config out of /etc/cinder/api-paste.ini
518 - Require python-cinderclient
520 * Mon Sep 3 2012 Pádraig Brady <P@draigBrady.com> - 2012.2-0.2.f3