From 8620101244ea5be1ff0cc0e127fa57dca4be468a Mon Sep 17 00:00:00 2001 From: Scott Little Date: Mon, 2 Oct 2017 14:28:46 -0400 Subject: [PATCH 4/6] WRS: 0001-meta-modify-aodh-api.patch Conflicts: SPECS/openstack-aodh.spec --- SOURCES/openstack-aodh-api.service | 2 +- SPECS/openstack-aodh.spec | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/SOURCES/openstack-aodh-api.service b/SOURCES/openstack-aodh-api.service index b8b2921..06bcd12 100644 --- a/SOURCES/openstack-aodh-api.service +++ b/SOURCES/openstack-aodh-api.service @@ -5,7 +5,7 @@ After=syslog.target network.target [Service] Type=simple User=root -ExecStart=/usr/bin/aodh-api +ExecStart=/bin/python /usr/bin/gunicorn --bind 192.168.204.2:8042 --pythonpath /usr/share/aodh aodh-api [Install] WantedBy=multi-user.target diff --git a/SPECS/openstack-aodh.spec b/SPECS/openstack-aodh.spec index 8c5722a..4acf6a0 100644 --- a/SPECS/openstack-aodh.spec +++ b/SPECS/openstack-aodh.spec @@ -20,6 +20,9 @@ Source14: %{name}-listener.service #WRS Source20: aodh-expirer-active +#WRS: Include patches here: +Patch1: 0001-modify-aodh-api.patch + BuildArch: noarch BuildRequires: openstack-macros @@ -214,6 +217,9 @@ This package contains the Aodh test files. %prep %setup -q -n %{pypi_name}-%{upstream_version} +#WRS: Apply patches here +%patch1 -p1 + find . \( -name .gitignore -o -name .placeholder \) -delete find aodh -name \*.py -exec sed -i '/\/usr\/bin\/env python/{d;q}' {} + @@ -260,6 +266,8 @@ install -d -m 755 %{buildroot}%{_sysconfdir}/aodh install -p -D -m 640 %{SOURCE1} %{buildroot}%{_datadir}/aodh/aodh-dist.conf install -p -D -m 640 aodh/aodh.conf %{buildroot}%{_sysconfdir}/aodh/aodh.conf install -p -D -m 640 aodh/api/policy.json %{buildroot}%{_sysconfdir}/aodh/policy.json +#WRS +install -p -D -m 640 aodh/api/aodh-api.py %{buildroot}%{_datadir}/aodh/aodh-api.py # Setup directories install -d -m 755 %{buildroot}%{_sharedstatedir}/aodh @@ -342,6 +350,7 @@ exit 0 %files common -f %{pypi_name}.lang %doc README.rst %dir %{_sysconfdir}/aodh +%{_datadir}/aodh/aodh-api.* %attr(-, root, aodh) %{_datadir}/aodh/aodh-dist.conf %config(noreplace) %attr(-, root, aodh) %{_sysconfdir}/aodh/aodh.conf %config(noreplace) %attr(-, root, aodh) %{_sysconfdir}/aodh/policy.json -- 2.7.4