Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:GA
python-azure-agent.2437
python-azure-agent.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File python-azure-agent.spec of Package python-azure-agent.2437
# # spec file for package python-azure-agent # # Copyright (c) 2015 SUSE LLC. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: python-azure-agent Summary: Microsoft Azure Linux Agent License: Apache-2.0 Group: System/Daemons Version: 2.1.4 Release: 0 Url: https://github.com/Azure/WALinuxAgent Source0: WALinuxAgent-%{version}.tar.gz Source1: 99-azure-timeout.rules Source2: 99-azure-product-uuid.rules Patch0: python-azure-agent-setup.diff Patch1: python-azure-agent-disable-test-check-pid.diff BuildRequires: dos2unix BuildRequires: python-devel BuildRequires: python-setuptools %if 0%{?suse_version} BuildRequires: python-xml %endif BuildRequires: udev %if 0%{?is_opensuse} || 0%{?suse_version} == 1310 || 0%{?suse_version} == 1320 BuildRequires: openSUSE-release %else BuildRequires: sles-release %endif %if 0%{?suse_version} > 1140 BuildRequires: systemd %endif # for unit tests BuildRequires: python-mock BuildRequires: python-pytest BuildRequires: openssl Requires: grep Requires: iptables Requires: logrotate %if 0%{?suse_version} < 1140 Requires: insserv Requires: sysvinit %endif Requires: openssh Requires: openssl Requires: pwdutils Requires: python-pyasn1 %if 0%{?suse_version} Requires: python-xml %endif Requires: sudo Requires: util-linux Conflicts: NetworkManager Conflicts: WALinuxAgent BuildRoot: %{_tmppath}/%{name}-%{version}-build %if 0%{?suse_version} && 0%{?suse_version} <= 1110 %{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %endif %if 0%{?suse_version} && 0%{?suse_version} > 1110 BuildArch: noarch %endif %description The azure-agent supports the provisioning and running of Linux VMs in the Microsoft Azure Public Cloud and Microsoft Azure Stack private cloud. This package should be installed on Linux disk images that are built to run withing the mivrosoft Azure framework. %package test Summary: Unit tests Group: Development/Languages/Python Requires: %{name} == %{version} Requires: python-mock Requires: python-pytest Requires: openssl %description test Unit tests for python-azure-agent. %prep %setup -qn WALinuxAgent-%{version} %patch0 -p1 cp %{SOURCE2} . %build python setup.py build %install %if 0%{?suse_version} > 1140 python setup.py install --prefix=%{_prefix} --lnx-distro='suse' --init-system='systemd' --root=%{buildroot} ln -s service %{buildroot}%{_sbindir}/rcwaagent %if 0%{?suse_version} < 1230 mkdir -p %{buildroot}/%{_unitdir} mv %{buildroot}/usr/lib/systemd/system/* %{buildroot}/%{_unitdir} rm -rf %{buildroot}/usr/lib/systemd %endif %else python setup.py install --prefix=%{_prefix} --lnx-distro='suse' --init-system='sysV' --root=%{buildroot} ### rc symlink ln -s ../..%{_initddir}/waagent %{buildroot}%{_sbindir}/rcwaagent %endif ### udev rules %if 0%{?suse_version} < 1230 mkdir -p %{buildroot}/lib/udev/rules.d install -D -m 0644 %{SOURCE1} %{buildroot}/lib/udev/rules.d/99-azure-timeout.rules install -D -m 0644 %{SOURCE2} %{buildroot}/lib/udev/rules.d/99-azure-product-uuid.rules %else mkdir -p %{buildroot}/usr/lib/udev/rules.d install -D -m 0644 %{SOURCE1} %{buildroot}/usr/lib/udev/rules.d/99-azure-timeout.rules install -D -m 0644 %{SOURCE2} %{buildroot}/usr/lib/udev/rules.d/99-azure-product-uuid.rules %endif ### log file ghost mkdir -p %{buildroot}/%{_localstatedir}/log touch %{buildroot}/%{_localstatedir}/log/waagent.log ### permissinon fixes chmod +x %{buildroot}/%{_sbindir}/waagent2.0 ### naming issues mv %{buildroot}/%{_sysconfdir}/logrotate.d/waagent.logrotate %{buildroot}/%{_sysconfdir}/logrotate.d/waagent # install tests cp -r tests %{buildroot}/%{python_sitelib}/azurelinuxagent %check # test distro/test_daemon.py test_check_pid fails w/o /proc, disable it patch -p1 < %PATCH1 # test utils/test_shell_util.py fails unless CTYPE is utf8 LC_CTYPE=en_US.utf8 py.test tests %pre %if 0%{?suse_version} > 1140 %service_add_pre waagent.service %endif %post %if 0%{?suse_version} > 1140 %service_add_post waagent.service %endif %preun %if 0%{?suse_version} > 1140 %service_del_preun waagent.service %else %stop_on_removal waagent %endif %postun %restart_on_update waagent %if 0%{?suse_version} > 1140 %service_del_postun waagent.service %else %insserv_cleanup %endif %files %defattr(0644,root,root,0755) %doc Changelog LICENSE-2.0.txt NOTICE README.md %{_sbindir}/rcwaagent %attr(0755,root,root) %{_sbindir}/waagent %attr(0755,root,root) %{_sbindir}/waagent2.0 %config(noreplace) %{_sysconfdir}/logrotate.d/waagent %config(noreplace) %{_sysconfdir}/waagent.conf %ghost %{_localstatedir}/log/waagent.log %if 0%{?suse_version} > 1140 %{_unitdir}/waagent.service %else %attr(0755,root,root) %{_initddir}/waagent %endif %if 0%{?suse_version} < 1230 /lib/udev/rules.d/99-azure-timeout.rules /lib/udev/rules.d/99-azure-product-uuid.rules %else /usr/lib/udev/rules.d/99-azure-timeout.rules /usr/lib/udev/rules.d/99-azure-product-uuid.rules %endif %dir %{python_sitelib}/azurelinuxagent %{python_sitelib} %exclude %{python_sitelib}/azurelinuxagent/tests %files test %defattr(0644,root,root,0755) %{python_sitelib}/azurelinuxagent/tests %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor