%global with_doc 0 %global service heat %global common_desc \ Heat is a service to orchestrate composite cloud applications using a \ declarative template format through an OpenStack-native REST API. Name: openstack-%{service} Summary: OpenStack Orchestration (%{service}) Version: 13.1.0 Release: 3 License: ASL 2.0 URL: http://www.openstack.org Source0: https://tarballs.openstack.org/%{service}/%{name}-%{version}.tar.gz Source1: %{service}.logrotate Source2: openstack-%{service}-api.service Source3: openstack-%{service}-api-cfn.service Source4: openstack-%{service}-engine.service Source6: openstack-%{service}-all.service BuildArch: noarch BuildRequires: git BuildRequires: openstack-macros BuildRequires: python3-devel BuildRequires: python3-stevedore BuildRequires: python3-oslo-cache BuildRequires: python3-oslo-context BuildRequires: python3-oslo-middleware BuildRequires: python3-oslo-policy BuildRequires: python3-oslo-messaging BuildRequires: python3-setuptools BuildRequires: python3-oslo-i18n BuildRequires: python3-oslo-db BuildRequires: python3-oslo-upgradecheck BuildRequires: python3-oslo-utils BuildRequires: python3-oslo-log BuildRequires: python3-oslo-versionedobjects BuildRequires: python3-eventlet BuildRequires: python3-kombu BuildRequires: python3-netaddr BuildRequires: python3-neutron-lib BuildRequires: python3-osprofiler BuildRequires: python3-six BuildRequires: python3-paramiko BuildRequires: python3-yaql # These are required to build due to the requirements check added BuildRequires: python3-routes BuildRequires: python3-sqlalchemy BuildRequires: python3-pbr BuildRequires: python3-cryptography # These are required to build the config file BuildRequires: python3-oslo-config BuildRequires: python3-keystoneauth1 BuildRequires: python3-keystoneclient BuildRequires: python3-tenacity # Required to compile translation files BuildRequires: python3-babel BuildRequires: python3-PyYAML BuildRequires: python3-lxml BuildRequires: python3-sqlalchemy-migrate BuildRequires: python3-paste-deploy BuildRequires: python3-redis BuildRequires: python3-webob BuildRequires: systemd %if 0%{?with_doc} BuildRequires: python3-openstackdocstheme BuildRequires: python3-sphinx BuildRequires: python3-sphinxcontrib-apidoc BuildRequires: python3-cinderclient BuildRequires: python3-novaclient BuildRequires: python3-saharaclient BuildRequires: python3-neutronclient BuildRequires: python3-swiftclient BuildRequires: python3-heatclient BuildRequires: python3-glanceclient BuildRequires: python3-troveclient BuildRequires: python3-aodhclient BuildRequires: python3-barbicanclient BuildRequires: python3-designateclient BuildRequires: python3-magnumclient BuildRequires: python3-monascaclient BuildRequires: python3-manilaclient BuildRequires: python3-zaqarclient BuildRequires: python3-croniter BuildRequires: python3-gabbi BuildRequires: python3-testscenarios BuildRequires: python3-tempest BuildRequires: python3-gabbi BuildRequires: python3-zunclient %endif Requires: %{name}-common = %{version}-%{release} Requires: %{name}-engine = %{version}-%{release} Requires: %{name}-api = %{version}-%{release} Requires: %{name}-api-cfn = %{version}-%{release} %description %{common_desc} %package common Summary: Heat common Group: System Environment/Base Requires: python3-heat = %{version}-%{release} %description common %{common_desc} This package contains scripts, config and dependencies shared between all the ${name} services %package api Summary: The Heat API Requires: %{name}-common = %{version}-%{release} %{?systemd_ordering} %description api %{common_desc} The %{service}-api component provides an OpenStack-native REST API that processes API requests by sending them to the %{service}-engine over RPC. %package api-cfn Summary: Heat CloudFormation API Requires: %{name}-common = %{version}-%{release} %{?systemd_ordering} %description api-cfn %{common_desc} The %{service}-api-cfn component provides an AWS Query API that is compatible with AWS CloudFormation and processes API requests by sending them to the %{service}-engine over RPC. %package engine Summary: The Heat engine Requires: %{name}-common = %{version}-%{release} %{?systemd_ordering} %description engine %{common_desc} The %{service}-engine's main responsibility is to orchestrate the launching of templates and provide events back to the API consumer. %package monolith Summary: The combined Heat engine/API Requires: %{name}-common = %{version}-%{release} %{?systemd_ordering} %description monolith %{common_desc} The %{service}-all process bundles together any (or all) of %{service}-engine, %{service}-api, and %{service}-cfn-api into a single process. This can be used to bootstrap a minimal TripleO deployment, but is not the recommended way of running the Heat service in general. %package -n python3-%{service} Summary: OpenStack Heat Python libraries Requires: python3-pbr Requires: python3-croniter Requires: python3-eventlet Requires: python3-stevedore Requires: python3-netaddr Requires: python3-neutron-lib Requires: python3-osprofiler Requires: python3-requests Requires: python3-routes Requires: python3-sqlalchemy Requires: python3-six Requires: python3-paramiko Requires: python3-babel # FIXME: system version is stuck to 1.7.2 for cryptography Requires: python3-cryptography Requires: python3-yaql Requires: python3-oslo-cache Requires: python3-oslo-concurrency Requires: python3-oslo-config Requires: python3-oslo-context Requires: python3-oslo-upgradecheck Requires: python3-oslo-utils Requires: python3-oslo-db Requires: python3-oslo-i18n Requires: python3-oslo-middleware Requires: python3-oslo-messaging Requires: python3-oslo-policy Requires: python3-oslo-reports Requires: python3-oslo-serialization Requires: python3-oslo-service Requires: python3-oslo-log Requires: python3-oslo-versionedobjects Requires: python3-cinderclient Requires: python3-glanceclient Requires: python3-heatclient Requires: python3-keystoneclient Requires: python3-keystonemiddleware Requires: python3-neutronclient Requires: python3-novaclient Requires: python3-saharaclient Requires: python3-swiftclient Requires: python3-troveclient Requires: python3-keystoneauth1 Requires: python3-barbicanclient Requires: python3-designateclient Requires: python3-manilaclient Requires: python3-mistralclient Requires: python3-openstackclient Requires: python3-zaqarclient Requires: python3-aodhclient Requires: python3-magnumclient Requires: python3-octaviaclient Requires: python3-monascaclient Requires: python3-blazarclient Requires: python3-zunclient Requires: python3-openstacksdk Requires: python3-tenacity Requires: python3-PyYAML Requires: python3-lxml Requires: python3-sqlalchemy-migrate Requires: python3-paste-deploy Requires: python3-webob Requires: python3-pytz Requires(pre): shadow-utils %description -n python3-%{service} %{common_desc} This package contains the %{service} Python library. %package -n python3-%{service}-tests %{?python_provide:%python_provide python3-%{service}-tests} Summary: Heat tests Requires: %{name}-common = %{version}-%{release} Requires: python3-mox3 Requires: python3-oslotest Requires: python3-testresources Requires: python3-oslotest Requires: python3-oslo-log Requires: python3-oslo-utils Requires: python3-heatclient Requires: python3-cinderclient Requires: python3-zaqarclient Requires: python3-keystoneclient Requires: python3-swiftclient Requires: python3-paramiko Requires: python3-kombu Requires: python3-oslo-config Requires: python3-oslo-concurrency Requires: python3-requests Requires: python3-eventlet Requires: python3-six Requires: python3-gabbi Requires: python3-PyYAML %description -n python3-%{service}-tests %{common_desc} This package contains the Heat test files. %prep %autosetup -n openstack-%{service}-%{version} -S git # Remove the requirements file so that pbr hooks don't add it # to distutils requires_dist config %py_req_cleanup # Remove tests in contrib find contrib -name tests -type d | xargs rm -r %build %{py3_build} # Generate i18n files %{__python3} setup.py compile_catalog -d build/lib/%{service}/locale %install %{py3_install} sed -i -e '/^#!/,1 d' %{buildroot}/%{python3_sitelib}/%{service}/db/sqlalchemy/migrate_repo/manage.py mkdir -p %{buildroot}/%{_localstatedir}/log/%{service}/ mkdir -p %{buildroot}/%{_localstatedir}/run/%{service}/ install -p -D -m 644 %{SOURCE1} %{buildroot}%{_sysconfdir}/logrotate.d/openstack-%{service} install -d -m 755 %{buildroot}%{_sysconfdir}/heat # Generate sample config mv %{buildroot}/%{_prefix}/%{_sysconfdir}/heat/* %{buildroot}%{_sysconfdir}/heat/ PYTHONPATH=. oslo-config-generator --config-file=config-generator.conf --output %{buildroot}%{_sysconfdir}/heat/heat.conf PYTHONPATH=. oslopolicy-sample-generator --config-file=etc/heat/heat-policy-generator.conf --output %{buildroot}%{_sysconfdir}/heat/policy.json rm etc/heat/heat-policy-generator.conf # install systemd unit files install -p -D -m 644 %{SOURCE2} %{buildroot}%{_unitdir}/openstack-%{service}-api.service install -p -D -m 644 %{SOURCE3} %{buildroot}%{_unitdir}/openstack-%{service}-api-cfn.service install -p -D -m 644 %{SOURCE4} %{buildroot}%{_unitdir}/openstack-%{service}-engine.service install -p -D -m 644 %{SOURCE2} %{buildroot}%{_unitdir}/openstack-%{service}-all.service mkdir -p %{buildroot}/%{_sharedstatedir}/%{service}/ mkdir -p %{buildroot}/%{_sysconfdir}/%{service}/ %if 0%{?with_doc} sphinx-build-3 -b html doc/source doc/build/html sphinx-build-3 -b man doc/source doc/build/man mkdir -p %{buildroot}%{_mandir}/man1 install -p -D -m 644 doc/build/man/*.1 %{buildroot}%{_mandir}/man1/ %endif rm -f %{buildroot}/%{_bindir}/%{service}-db-setup rm -f %{buildroot}/%{_mandir}/man1/%{service}-db-setup.* rm -rf %{buildroot}/var/lib/%{service}/.dummy rm -f %{buildroot}/usr/bin/cinder-keystone-setup #install -p -D -m 640 etc/%{service}/%{service}.conf.sample %{buildroot}/%{_sysconfdir}/%{service}/%{service}.conf #mv %{buildroot}/%{_prefix}/%{_sysconfdir}/heat/* %{buildroot}%{_sysconfdir}/heat # Install i18n .mo files (.po and .pot are not required) install -d -m 755 %{buildroot}%{_datadir} rm -f %{buildroot}%{python3_sitelib}/%{service}/locale/*/LC_*/%{service}*po rm -f %{buildroot}%{python3_sitelib}/%{service}/locale/*pot mv %{buildroot}%{python3_sitelib}/%{service}/locale %{buildroot}%{_datadir}/locale # Find language files %find_lang %{service} --all-name %pre common %openstack_pre_user_group_create %{service} %{service} /sbin/nologin exit 0 %post api %systemd_post openstack-%{service}-api.service %post api-cfn %systemd_post openstack-%{service}-api-cfn.service %post engine %systemd_post openstack-%{service}-engine.service %post monolith %systemd_post openstack-%{service}-all.service %preun api %systemd_preun openstack-%{service}-api.service %preun api-cfn %systemd_preun openstack-%{service}-api-cfn.service %preun engine %systemd_preun openstack-%{service}-engine.service %preun monolith %systemd_preun openstack-%{service}-all.service %postun engine %systemd_postun_with_restart openstack-%{service}-engine.service %postun api %systemd_postun_with_restart openstack-%{service}-api.service %postun api-cfn %systemd_postun_with_restart openstack-%{service}-api-cfn.service %postun monolith %systemd_postun_with_restart openstack-%{service}-all.service %files %files common -f %{service}.lang %doc LICENSE %{_bindir}/%{service}-manage %{_bindir}/%{service}-status %{_bindir}/%{service}-keystone-setup %{_bindir}/%{service}-keystone-setup-domain %{python3_sitelib}/%{service} %{python3_sitelib}/openstack_%{service}-%{version}-*.egg-info %exclude %{python3_sitelib}/%{service}/tests %dir %attr(0755,%{service},root) %{_localstatedir}/log/%{service} %dir %attr(0755,%{service},root) %{_localstatedir}/run/%{service} %dir %attr(0755,%{service},root) %{_sharedstatedir}/%{service} %dir %attr(0755,%{service},root) %{_sysconfdir}/%{service} %config(noreplace) %{_sysconfdir}/logrotate.d/openstack-%{service} %config(noreplace) %attr(0640, root, %{service}) %{_sysconfdir}/%{service}/%{service}.conf %config(noreplace) %attr(0640, root, %{service}) %{_sysconfdir}/%{service}/environment.d/* %config(noreplace) %attr(0640, root, %{service}) %{_sysconfdir}/%{service}/templates/* %config(noreplace) %attr(0640, root, %{service}) %{_sysconfdir}/%{service}/api-paste.ini %config(noreplace) %attr(0640, root, %{service}) %{_sysconfdir}/%{service}/policy.json %if 0%{?with_doc} %{_mandir}/man1/%{service}-keystone-setup.1.gz %{_mandir}/man1/%{service}-keystone-setup-domain.1.gz %{_mandir}/man1/%{service}-manage.1.gz %{_mandir}/man1/%{service}-status.1.gz %endif %files api %doc README.rst LICENSE %if 0%{?with_doc} %doc doc/build/html/man/%{service}-api.html %endif %{_bindir}/%{service}-api %{_bindir}/%{service}-wsgi-api %{_unitdir}/openstack-%{service}-api.service %if 0%{?with_doc} %{_mandir}/man1/%{service}-api.1.gz %endif %files api-cfn %doc README.rst LICENSE %if 0%{?with_doc} %doc doc/build/html/man/%{service}-api-cfn.html %endif %{_bindir}/%{service}-api-cfn %{_bindir}/%{service}-wsgi-api-cfn %{_unitdir}/openstack-%{service}-api-cfn.service %if 0%{?with_doc} %{_mandir}/man1/%{service}-api-cfn.1.gz %endif %files engine %doc README.rst LICENSE %if 0%{?with_doc} %doc doc/build/html/man/%{service}-engine.html %endif %{_bindir}/%{service}-engine %{_unitdir}/openstack-%{service}-engine.service %if 0%{?with_doc} %{_mandir}/man1/%{service}-engine.1.gz %endif %files monolith %doc README.rst LICENSE %{_bindir}/%{service}-all %{_unitdir}/openstack-%{service}-all.service %files -n python3-%{service} %license LICENSE %{python3_sitelib}/%{service}/ %{python3_sitelib}/openstack_heat-*.egg-info %exclude %{python3_sitelib}/%{service}/tests %if 0%{?with_doc} %files doc %license LICENSE %doc doc/build/html %endif %files -n python3-%{service}-tests %license LICENSE %{python3_sitelib}/%{service}/tests %{python3_sitelib}/%{service}_integrationtests %changelog * Tue Nov 30 2021 huangtiahua - 13.1.0-3 - Reorganize to satisfy OpenStack SIG architecture rule * Fri Nov 12 2021 wangxiyuan - 13.1.0-2 - Fix build issue * Fri Nov 05 2021 huangtiahua - 13.1.0-1 - Init Heat to 13.1.0