Sync from SUSE:ALP:Source:Standard:1.0 python-azure-agent revision 1d9bca917a95f673a7a42b1bef33de07
This commit is contained in:
parent
01af9e93b5
commit
cec192301d
11
agent-btrfs-use-f.patch
Normal file
11
agent-btrfs-use-f.patch
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
--- azurelinuxagent/daemon/resourcedisk/default.py.orig
|
||||||
|
+++ azurelinuxagent/daemon/resourcedisk/default.py
|
||||||
|
@@ -124,7 +124,7 @@ class ResourceDiskHandler(object):
|
||||||
|
"{0}: {1}".format(device, ret[1]))
|
||||||
|
|
||||||
|
force_option = 'F'
|
||||||
|
- if self.fs == 'xfs':
|
||||||
|
+ if self.fs in ('btrfs', 'xfs'):
|
||||||
|
force_option = 'f'
|
||||||
|
mkfs_string = "mkfs.{0} -{2} {1}".format(
|
||||||
|
self.fs, partition, force_option)
|
@ -1,3 +1,47 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Jul 12 15:41:55 UTC 2024 - Robert Schweikert <rjschwei@suse.com>
|
||||||
|
|
||||||
|
- Add agent-btrfs-use-f.patch (bsc#1227711)
|
||||||
|
+ Use the proper option to force btrfs to overwrite a file system on the
|
||||||
|
resource disk if one already exists.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jul 10 15:09:56 UTC 2024 - Joachim Gleissner <jgleissner@suse.com>
|
||||||
|
|
||||||
|
- Set Provisioning.Agent parameter to 'cloud-init' in SLE Micro >= 5.5
|
||||||
|
(bsc#1227106).
|
||||||
|
- Do not package waagent2.0 in Python 3 builds.
|
||||||
|
- Drop obsolete otherproviders keyword from Conflicts statements
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Jul 1 09:53:19 UTC 2024 - Joachim Gleissner <jgleissner@suse.com>
|
||||||
|
|
||||||
|
- Do not require wicked in non-SUSE build environments.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jun 26 10:14:35 UTC 2024 - Joachim Gleissner <jgleissner@suse.com>
|
||||||
|
|
||||||
|
- Apply python3 interpreter patch in non SLE build environments
|
||||||
|
(bcs#1227067)
|
||||||
|
- Simplify %suse_version conditionals
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jun 5 18:58:43 UTC 2024 - Robert Schweikert <rjschwei@suse.com>
|
||||||
|
|
||||||
|
- Use the -Z option for mv and cp in the posttrans to properly handle
|
||||||
|
SELinux context (bsc#1225946)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Apr 10 22:53:47 UTC 2024 - Robert Schweikert <rjschwei@suse.com>
|
||||||
|
|
||||||
|
- Keep the existing config file (bsc#1222620)
|
||||||
|
+ During separation of the config file into subpackages it was forgotten
|
||||||
|
that on update of the main package the previously provided config file
|
||||||
|
would be removed. SInce we do not know which flavor of our images the
|
||||||
|
package is being upgraded on, preserve the previously existing config
|
||||||
|
file. This will orphan the file if non of the -config-* packages gets
|
||||||
|
installed.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Feb 20 20:07:51 UTC 2024 - Robert Schweikert <rjschwei@suse.com>
|
Tue Feb 20 20:07:51 UTC 2024 - Robert Schweikert <rjschwei@suse.com>
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-azure-agent
|
# spec file for package python-azure-agent
|
||||||
#
|
#
|
||||||
# Copyright (c) 2023 SUSE LLC
|
# Copyright (c) 2024 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -31,12 +31,14 @@ Patch8: paa_12_sp5_rdma_no_ext_driver.patch
|
|||||||
# PATCH-FIX-UPSTREAM gh#Azure/WALinuxAgent#2741
|
# PATCH-FIX-UPSTREAM gh#Azure/WALinuxAgent#2741
|
||||||
Patch9: remove-mock.patch
|
Patch9: remove-mock.patch
|
||||||
Patch10: agent-micro-is-sles.patch
|
Patch10: agent-micro-is-sles.patch
|
||||||
|
# PATCH-FIX-UPSTREAM gh#Azure/WALinuxAgent#3158
|
||||||
|
Patch11: agent-btrfs-use-f.patch
|
||||||
BuildRequires: dos2unix
|
BuildRequires: dos2unix
|
||||||
|
|
||||||
BuildRequires: distribution-release
|
BuildRequires: distribution-release
|
||||||
BuildRequires: openssl
|
BuildRequires: openssl
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
BuildRequires: python3-distro
|
BuildRequires: python3-distro
|
||||||
BuildRequires: python3-setuptools
|
BuildRequires: python3-setuptools
|
||||||
%else
|
%else
|
||||||
@ -56,7 +58,7 @@ Requires: sysvinit-tools
|
|||||||
%if 0%{?suse_version} && 0%{?suse_version} <= 1500
|
%if 0%{?suse_version} && 0%{?suse_version} <= 1500
|
||||||
Requires: wicked
|
Requires: wicked
|
||||||
%endif
|
%endif
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
Requires: python3-distro
|
Requires: python3-distro
|
||||||
Requires: python3-pyasn1
|
Requires: python3-pyasn1
|
||||||
Requires: python3-xml
|
Requires: python3-xml
|
||||||
@ -102,7 +104,7 @@ Summary: Default upstream configuration
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Requires: %{name} == %{version}
|
Requires: %{name} == %{version}
|
||||||
Provides: waagent-config
|
Provides: waagent-config
|
||||||
Conflicts: otherproviders(waagent-config)
|
Conflicts: waagent-config
|
||||||
|
|
||||||
%description config-default
|
%description config-default
|
||||||
The default configuration for the agent as supplied by upstream for SUSE
|
The default configuration for the agent as supplied by upstream for SUSE
|
||||||
@ -112,7 +114,7 @@ Summary: SUSE specific configuration for server products
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Requires: %{name} == %{version}
|
Requires: %{name} == %{version}
|
||||||
Provides: waagent-config
|
Provides: waagent-config
|
||||||
Conflicts: otherproviders(waagent-config)
|
Conflicts: waagent-config
|
||||||
|
|
||||||
%description config-server
|
%description config-server
|
||||||
Modified waagent.conf file to meet SUSE policies and SUSE image build
|
Modified waagent.conf file to meet SUSE policies and SUSE image build
|
||||||
@ -123,7 +125,7 @@ Summary: SUSE specific configuration for HPC
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Requires: %{name} == %{version}
|
Requires: %{name} == %{version}
|
||||||
Provides: waagent-config
|
Provides: waagent-config
|
||||||
Conflicts: otherproviders(waagent-config)
|
Conflicts: waagent-config
|
||||||
|
|
||||||
%description config-hpc
|
%description config-hpc
|
||||||
Modified waagent.conf file to meet SUSE policies and SUSE image build
|
Modified waagent.conf file to meet SUSE policies and SUSE image build
|
||||||
@ -134,7 +136,7 @@ Summary: SUSE specific configuration for Micro
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Requires: %{name} == %{version}
|
Requires: %{name} == %{version}
|
||||||
Provides: waagent-config
|
Provides: waagent-config
|
||||||
Conflicts: otherproviders(waagent-config)
|
Conflicts: waagent-config
|
||||||
|
|
||||||
%description config-micro
|
%description config-micro
|
||||||
Modified waagent.conf file to meet SUSE policies and SUSE image build
|
Modified waagent.conf file to meet SUSE policies and SUSE image build
|
||||||
@ -143,24 +145,26 @@ setup
|
|||||||
%prep
|
%prep
|
||||||
%setup -qn WALinuxAgent-%{version}
|
%setup -qn WALinuxAgent-%{version}
|
||||||
%patch -P 1
|
%patch -P 1
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315 && 0%{?sle_version}
|
%if 0%{?suse_version} > 1315
|
||||||
%patch -P 6
|
%patch -P 6
|
||||||
%endif
|
%endif
|
||||||
%patch -P 7
|
%patch -P 7
|
||||||
%patch -P 8
|
%patch -P 8
|
||||||
%patch -P 9 -p1
|
%patch -P 9 -p1
|
||||||
%patch -P 10
|
%patch -P 10
|
||||||
|
%patch -P 11
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
python3 setup.py build
|
python3 setup.py build
|
||||||
%else
|
%else
|
||||||
python setup.py build
|
python setup.py build
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
python3 setup.py install --prefix=%{_prefix} --lnx-distro='suse' --root=%{buildroot}
|
python3 setup.py install --prefix=%{_prefix} --lnx-distro='suse' --root=%{buildroot}
|
||||||
|
rm %{buildroot}/usr/sbin/waagent2.0
|
||||||
%else
|
%else
|
||||||
python setup.py install --prefix=%{_prefix} --lnx-distro='suse' --root=%{buildroot}
|
python setup.py install --prefix=%{_prefix} --lnx-distro='suse' --root=%{buildroot}
|
||||||
%endif
|
%endif
|
||||||
@ -185,8 +189,10 @@ cp %{buildroot}%{_sysconfdir}/waagent.conf %{buildroot}%{_sysconfdir}/waagent.co
|
|||||||
# Micro setup
|
# Micro setup
|
||||||
# Undo the HPC change
|
# Undo the HPC change
|
||||||
sed -i -e "s/OS.EnableRDMA=y/# OS.EnableRDMA=y/" %{buildroot}%{_sysconfdir}/waagent.conf
|
sed -i -e "s/OS.EnableRDMA=y/# OS.EnableRDMA=y/" %{buildroot}%{_sysconfdir}/waagent.conf
|
||||||
# Use Ignition/Afterburn in Micro
|
%if 0%{?sle_version} && 0%{?sle_version} < 150500
|
||||||
|
# Use Ignition/Afterburn in Micro < 5.5
|
||||||
sed -i -e "s/Provisioning.Agent=cloud-init/Provisioning.Agent=disabled/" %{buildroot}%{_sysconfdir}/waagent.conf
|
sed -i -e "s/Provisioning.Agent=cloud-init/Provisioning.Agent=disabled/" %{buildroot}%{_sysconfdir}/waagent.conf
|
||||||
|
%endif
|
||||||
# No extension support for transactional-upfdate systems
|
# No extension support for transactional-upfdate systems
|
||||||
# There's an inherant bug in that root password reset is also treated via this
|
# There's an inherant bug in that root password reset is also treated via this
|
||||||
# switch
|
# switch
|
||||||
@ -213,8 +219,6 @@ mv %{buildroot}%{_sysconfdir}/udev/rules.d/* %{buildroot}/usr/lib/udev/rules.d/
|
|||||||
### log file ghost
|
### log file ghost
|
||||||
mkdir -p %{buildroot}/%{_localstatedir}/log
|
mkdir -p %{buildroot}/%{_localstatedir}/log
|
||||||
touch %{buildroot}/%{_localstatedir}/log/waagent.log
|
touch %{buildroot}/%{_localstatedir}/log/waagent.log
|
||||||
### permissinon fixes
|
|
||||||
chmod +x %{buildroot}/%{_sbindir}/waagent2.0
|
|
||||||
### naming issues
|
### naming issues
|
||||||
%if 0%{?suse_version} > 1500
|
%if 0%{?suse_version} > 1500
|
||||||
mkdir -p %{buildroot}%{_distconfdir}/logrotate.d
|
mkdir -p %{buildroot}%{_distconfdir}/logrotate.d
|
||||||
@ -224,7 +228,7 @@ mv %{buildroot}/%{_sysconfdir}/logrotate.d/waagent.logrotate %{buildroot}/%{_sys
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
# install tests
|
# install tests
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
cp -r tests %{buildroot}/%{python3_sitelib}/azurelinuxagent
|
cp -r tests %{buildroot}/%{python3_sitelib}/azurelinuxagent
|
||||||
%else
|
%else
|
||||||
cp -r tests %{buildroot}/%{python_sitelib}/azurelinuxagent
|
cp -r tests %{buildroot}/%{python_sitelib}/azurelinuxagent
|
||||||
@ -232,6 +236,13 @@ cp -r tests %{buildroot}/%{python_sitelib}/azurelinuxagent
|
|||||||
|
|
||||||
%pre
|
%pre
|
||||||
%service_add_pre waagent.service
|
%service_add_pre waagent.service
|
||||||
|
# Handle the case when the -config-* package is not installed, we want to
|
||||||
|
# preserver the previousl config file that was flavor customized during
|
||||||
|
# image build
|
||||||
|
if [ -e /etc/waagent.conf ]; then
|
||||||
|
cp -Z /etc/waagent.conf /etc/waagent.conf.bak
|
||||||
|
fi
|
||||||
|
|
||||||
%if 0%{?suse_version} > 1500
|
%if 0%{?suse_version} > 1500
|
||||||
# Prepare for migration to /usr/etc; save any old .rpmsave
|
# Prepare for migration to /usr/etc; save any old .rpmsave
|
||||||
for i in logrotate.d/waagent ; do
|
for i in logrotate.d/waagent ; do
|
||||||
@ -239,8 +250,19 @@ for i in logrotate.d/waagent ; do
|
|||||||
done
|
done
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if 0%{?suse_version} > 1500
|
|
||||||
%posttrans
|
%posttrans
|
||||||
|
# Do not clobber the config if it was installed from a config package, but
|
||||||
|
# put the oldfile back if we do not have another config file
|
||||||
|
if [ ! -e /etc/waagent.conf ]; then
|
||||||
|
if [ -e /etc/waagent.conf.bak ]; then
|
||||||
|
mv -Z /etc/waagent.conf.bak /etc/waagent.conf
|
||||||
|
# Making the assumption that the rpmsave file was generated because of
|
||||||
|
# of the previously broken package upgrade.
|
||||||
|
elif [ -e /etc/waagent.conf.rpmsave ]; then
|
||||||
|
cp -Z /etc/waagent.conf.rpmsave /etc/waagent.conf
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
%if 0%{?suse_version} > 1500
|
||||||
# Migration to /usr/etc, restore just created .rpmsave
|
# Migration to /usr/etc, restore just created .rpmsave
|
||||||
for i in logrotate.d/waagent ; do
|
for i in logrotate.d/waagent ; do
|
||||||
test -f %{_sysconfdir}/${i}.rpmsave && mv -v %{_sysconfdir}/${i}.rpmsave %{_sysconfdir}/${i} ||:
|
test -f %{_sysconfdir}/${i}.rpmsave && mv -v %{_sysconfdir}/${i}.rpmsave %{_sysconfdir}/${i} ||:
|
||||||
@ -280,7 +302,6 @@ ln -s %{_sysconfdir}/waagent.conf.micro %{_sysconfdir}/waagent.conf
|
|||||||
%exclude %{_sysconfdir}/waagent.conf*
|
%exclude %{_sysconfdir}/waagent.conf*
|
||||||
%{_sbindir}/rcwaagent
|
%{_sbindir}/rcwaagent
|
||||||
%attr(0755,root,root) %{_sbindir}/waagent
|
%attr(0755,root,root) %{_sbindir}/waagent
|
||||||
%attr(0755,root,root) %{_sbindir}/waagent2.0
|
|
||||||
%if 0%{?suse_version} > 1500
|
%if 0%{?suse_version} > 1500
|
||||||
%{_distconfdir}/logrotate.d/waagent
|
%{_distconfdir}/logrotate.d/waagent
|
||||||
%else
|
%else
|
||||||
@ -295,19 +316,20 @@ ln -s %{_sysconfdir}/waagent.conf.micro %{_sysconfdir}/waagent.conf
|
|||||||
/usr/lib/udev/rules.d/66-azure-storage.rules
|
/usr/lib/udev/rules.d/66-azure-storage.rules
|
||||||
/usr/lib/udev/rules.d/99-azure-product-uuid.rules
|
/usr/lib/udev/rules.d/99-azure-product-uuid.rules
|
||||||
%endif
|
%endif
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
%dir %{python3_sitelib}/azurelinuxagent
|
%dir %{python3_sitelib}/azurelinuxagent
|
||||||
%{python3_sitelib}
|
%{python3_sitelib}
|
||||||
%exclude %{python3_sitelib}/azurelinuxagent/tests
|
%exclude %{python3_sitelib}/azurelinuxagent/tests
|
||||||
%else
|
%else
|
||||||
%dir %{python_sitelib}/azurelinuxagent
|
%dir %{python_sitelib}/azurelinuxagent
|
||||||
|
%attr(0755,root,root) %{_sbindir}/waagent2.0
|
||||||
%{python_sitelib}
|
%{python_sitelib}
|
||||||
%exclude %{python_sitelib}/azurelinuxagent/tests
|
%exclude %{python_sitelib}/azurelinuxagent/tests
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%files test
|
%files test
|
||||||
%defattr(0644,root,root,0755)
|
%defattr(0644,root,root,0755)
|
||||||
%if 0%{?suse_version} && 0%{?suse_version} > 1315
|
%if 0%{?suse_version} > 1315
|
||||||
%{python3_sitelib}/azurelinuxagent/tests
|
%{python3_sitelib}/azurelinuxagent/tests
|
||||||
%else
|
%else
|
||||||
%{python_sitelib}/azurelinuxagent/tests
|
%{python_sitelib}/azurelinuxagent/tests
|
||||||
|
Loading…
Reference in New Issue
Block a user