Accepting request 869058 from Virtualization:containers
- Update to handle the docker-runc removal, and drop the -kubic flavour. bsc#1181677 bsc#1181749 - Update to containerd v1.4.3, which is needed for Docker v20.10.2-ce. bsc#1181594 - Install the containerd-shim* binaries and stop creating docker-containerd-shim because that isn't used by Docker anymore. OBS-URL: https://build.opensuse.org/request/show/869058 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/containerd?expand=0&rev=38
This commit is contained in:
commit
d2b34f5fe5
@ -1,3 +0,0 @@
|
||||
<multibuild>
|
||||
<package>kubic</package>
|
||||
</multibuild>
|
4
_service
4
_service
@ -3,8 +3,8 @@
|
||||
<param name="url">https://github.com/containerd/containerd.git</param>
|
||||
<param name="scm">git</param>
|
||||
<param name="filename">containerd</param>
|
||||
<param name="versionformat">1.3.9_%h</param>
|
||||
<param name="revision">v1.3.9</param>
|
||||
<param name="versionformat">1.4.3_%h</param>
|
||||
<param name="revision">v1.4.3</param>
|
||||
<param name="exclude">.git</param>
|
||||
</service>
|
||||
<service name="recompress" mode="disabled">
|
||||
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e401bedfeeaa467649781cb07b202b32b80e731aa6f5d4229e7c8315f9283fdc
|
||||
size 3150524
|
3
containerd-1.4.3_269548fa27e0.tar.xz
Normal file
3
containerd-1.4.3_269548fa27e0.tar.xz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:54dbc0fa5ee2dc13fe6bc8d2c2cd4c3a05e1e156820748506bb19f6a4c129aeb
|
||||
size 3595656
|
@ -1,3 +1,17 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Feb 2 05:33:02 UTC 2021 - Aleksa Sarai <asarai@suse.com>
|
||||
|
||||
- Update to handle the docker-runc removal, and drop the -kubic flavour.
|
||||
bsc#1181677 bsc#1181749
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 29 23:24:30 UTC 2021 - Aleksa Sarai <asarai@suse.com>
|
||||
|
||||
- Update to containerd v1.4.3, which is needed for Docker v20.10.2-ce.
|
||||
bsc#1181594
|
||||
- Install the containerd-shim* binaries and stop creating
|
||||
docker-containerd-shim because that isn't used by Docker anymore.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 21 06:53:15 UTC 2020 - Aleksa Sarai <asarai@suse.com>
|
||||
|
||||
|
120
containerd.spec
120
containerd.spec
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package containerd
|
||||
#
|
||||
# Copyright (c) 2020 SUSE LLC
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -22,30 +22,19 @@
|
||||
%define _fillupdir /var/adm/fillup-templates
|
||||
%endif
|
||||
|
||||
# Handle _multibuild magic.
|
||||
%define flavour @BUILD_FLAVOR@%{nil}
|
||||
|
||||
# We split the Name: into "realname" and "name_suffix".
|
||||
%define realname containerd
|
||||
%if "%flavour" == ""
|
||||
%define name_suffix %{nil}
|
||||
%else
|
||||
%define name_suffix -%{flavour}
|
||||
%endif
|
||||
|
||||
# MANUAL: Update the git_version.
|
||||
%define git_version ea765aba0d05254012b0b9e595e995c09186427f
|
||||
%define git_short ea765aba0d05
|
||||
%define git_version 269548fa27e0089a8b8278fc4fc781d7f65a939b
|
||||
%define git_short 269548fa27e0
|
||||
|
||||
Name: %{realname}%{name_suffix}
|
||||
Version: 1.3.9
|
||||
Name: containerd
|
||||
Version: 1.4.3
|
||||
Release: 0
|
||||
Summary: Standalone OCI Container Daemon
|
||||
License: Apache-2.0
|
||||
Group: System/Management
|
||||
URL: https://containerd.tools
|
||||
Source: %{realname}-%{version}_%{git_short}.tar.xz
|
||||
Source1: %{realname}-rpmlintrc
|
||||
Source: %{name}-%{version}_%{git_short}.tar.xz
|
||||
Source1: %{name}-rpmlintrc
|
||||
# OPENSUSE-FIX-UPSTREAM: Backport of https://github.com/containerd/containerd/pull/2764.
|
||||
Patch1: 0001-makefile-remove-emoji.patch
|
||||
BuildRequires: fdupes
|
||||
@ -61,25 +50,15 @@ BuildRequires: go1.13
|
||||
Provides: %{name}-git = %{git_version}
|
||||
# Currently runc is the only supported runtime for containerd. We pin the same
|
||||
# flavour as us, to avoid mixing (the version pinning is done by docker.spec).
|
||||
Requires: docker-runc%{name_suffix}
|
||||
Requires: runc
|
||||
Requires(post): %fillup_prereq
|
||||
# KUBIC-SPECIFIC: There used to be a kubic-specific containerd package, but now
|
||||
# it's been merged into the one package. bsc#1181677
|
||||
Obsoletes: %{name}-kubic < %{version}
|
||||
Provides: %{name}-kubic = %{version}
|
||||
Obsoletes: %{name} = 0.2.5+gitr569_2a5e70c
|
||||
Obsoletes: %{name}_2a5e70c
|
||||
ExcludeArch: s390
|
||||
# KUBIC-SPECIFIC: This was required when upgrading from the original kubic
|
||||
# packaging, when everything was renamed to -kubic. It also is
|
||||
# used to ensure that nothing complains too much when using
|
||||
# -kubic packages. Hopfully it can be removed one day.
|
||||
%if "%flavour" == "kubic"
|
||||
# Obsolete older package without -kubic suffix: v2 -> v3
|
||||
Obsoletes: %{realname} = 0.2.5+gitr569_2a5e70c
|
||||
Obsoletes: %{realname}_2a5e70c
|
||||
# Conflict with non-kubic package, and provide equivalent
|
||||
Conflicts: %{realname} > 0.2.5+gitr569_2a5e70c
|
||||
Provides: %{realname} = %{version}
|
||||
# Disable leap based builds for kubic flavor (bsc#1121412)
|
||||
%if 0%{?suse_version} == 1500 && 0%{?is_opensuse}
|
||||
ExclusiveArch: do_not_build
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%description
|
||||
Containerd is a daemon with an API and a command line client, to manage
|
||||
@ -92,27 +71,24 @@ migration of containers.
|
||||
Summary: Client for %{name}
|
||||
Group: System/Management
|
||||
Requires: %{name} = %{version}
|
||||
# KUBIC-SPECIFIC: This was required when upgrading from the original kubic
|
||||
# packaging, when everything was renamed to -kubic. It also is
|
||||
# used to ensure that nothing complains too much when using
|
||||
# -kubic packages. Hopfully it can be removed one day.
|
||||
%if "%flavour" == "kubic"
|
||||
# Obsolete older package without -kubic suffix: v2 -> v3
|
||||
Obsoletes: %{realname}-ctr = 0.2.5+gitr569_2a5e70c
|
||||
# Conflict with non-kubic package, and provide equivalent
|
||||
Conflicts: %{realname}-ctr > 0.2.5+gitr569_2a5e70c
|
||||
Provides: %{realname}-ctr = %{version}
|
||||
%endif
|
||||
# KUBIC-SPECIFIC: There used to be a kubic-specific containerd package, but now
|
||||
# it's been merged into the one package.
|
||||
Obsoletes: %{name}-ctr = 0.2.5+gitr569_2a5e70c
|
||||
Obsoletes: %{name}-ctr-kubic <= %{version}
|
||||
Obsoletes: %{name}-ctr_2a5e70c
|
||||
|
||||
%description ctr
|
||||
Standalone client for containerd, which allows management of containerd containers
|
||||
separately from Docker.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{realname}-%{version}_%{git_short}
|
||||
%setup -q -n %{name}-%{version}_%{git_short}
|
||||
%patch1 -p1
|
||||
|
||||
%build
|
||||
# NOTE: containerd will switch to go.mod in 1.5.x so this can be removed after
|
||||
# we update to that version.
|
||||
|
||||
# Do not use symlinks. If you want to run the unit tests for this package at
|
||||
# some point during the build and you need to directly use go list directly it
|
||||
# will get confused by symlinks.
|
||||
@ -123,39 +99,29 @@ rm -rf $PROJECT/*
|
||||
cp -ar * $PROJECT
|
||||
|
||||
BUILDTAGS="apparmor selinux seccomp"
|
||||
make -C $PROJECT \
|
||||
make -C "$PROJECT"\
|
||||
BUILDTAGS="$BUILDTAGS" \
|
||||
VERSION="v%{version}" \
|
||||
REVISION="%{git_version}"
|
||||
# TODO: Fix man-page generation.
|
||||
#make man
|
||||
|
||||
cp $PROJECT/bin/ctr ctr-%{version}
|
||||
cp $PROJECT/bin/containerd containerd-%{version}
|
||||
cp $PROJECT/bin/containerd-shim containerd-shim-%{version}
|
||||
|
||||
%check
|
||||
# We used to run 'go test' here, however we found that this actually didn't
|
||||
# catch any issues that were caught by smoke testing, and %check would
|
||||
# continually cause package builds to fail due to flaky tests. If you ever need
|
||||
# to know how the testing was done, you can always look in the package history.
|
||||
# boo#1095817
|
||||
cp -r "$PROJECT/bin" bin
|
||||
|
||||
%install
|
||||
# Install binaries.
|
||||
install -D -m755 containerd-%{version} %{buildroot}/%{_sbindir}/%{realname}
|
||||
install -D -m755 containerd-shim-%{version} %{buildroot}/%{_sbindir}/%{realname}-shim
|
||||
install -D -m755 ctr-%{version} %{buildroot}/%{_sbindir}/%{realname}-ctr
|
||||
|
||||
# Install docker-* symlinks to said binaries, since in order to use the
|
||||
# upstream setup, Docker needs to spawn containerd and needs to have the
|
||||
# binaries have specific names.
|
||||
ln -s %{_sbindir}/%{realname} %{buildroot}/%{_sbindir}/docker-%{realname}
|
||||
ln -s %{_sbindir}/%{realname}-shim %{buildroot}/%{_sbindir}/docker-%{realname}-shim
|
||||
pushd bin/
|
||||
for bin in containerd{,-shim*}
|
||||
do
|
||||
install -D -m755 "$bin" "%{buildroot}/%{_sbindir}/$bin"
|
||||
done
|
||||
# "ctr" is a bit too generic.
|
||||
install -D -m755 ctr %{buildroot}/%{_sbindir}/%{name}-ctr
|
||||
popd
|
||||
|
||||
# Set up dummy configuration.
|
||||
install -d -m755 %{buildroot}/%{_sysconfdir}/%{realname}
|
||||
echo "# See containerd-config.toml(5) for documentation." >%{buildroot}/%{_sysconfdir}/%{realname}/config.toml
|
||||
install -d -m755 %{buildroot}/%{_sysconfdir}/%{name}
|
||||
echo "# See containerd-config.toml(5) for documentation." >%{buildroot}/%{_sysconfdir}/%{name}/config.toml
|
||||
|
||||
# Man pages.
|
||||
# TODO: Fix man page generation.
|
||||
@ -164,7 +130,7 @@ echo "# See containerd-config.toml(5) for documentation." >%{buildroot}/%{_sysco
|
||||
# section="${file##*.}"
|
||||
# install -D -m644 "$file" "%{buildroot}/%{_mandir}/man$section/$(basename "$file")"
|
||||
#done
|
||||
#ln -s ctr.1 %{buildroot}/%{_mandir}/man1/%{realname}-ctr.1
|
||||
#ln -s ctr.1 %{buildroot}/%{_mandir}/man1/%{name}-ctr.1
|
||||
|
||||
%fdupes %{buildroot}
|
||||
|
||||
@ -172,18 +138,16 @@ echo "# See containerd-config.toml(5) for documentation." >%{buildroot}/%{_sysco
|
||||
%defattr(-,root,root)
|
||||
%doc README.md
|
||||
%license LICENSE
|
||||
%dir %{_sysconfdir}/%{realname}
|
||||
%config %{_sysconfdir}/%{realname}/config.toml
|
||||
%{_sbindir}/%{realname}
|
||||
%{_sbindir}/docker-%{realname}
|
||||
%{_sbindir}/%{realname}-shim
|
||||
%{_sbindir}/docker-%{realname}-shim
|
||||
%dir %{_sysconfdir}/%{name}
|
||||
%config %{_sysconfdir}/%{name}/config.toml
|
||||
%{_sbindir}/containerd
|
||||
%{_sbindir}/containerd-shim*
|
||||
# TODO: Fix man page generation.
|
||||
#%{_mandir}/man*/%{realname}*
|
||||
#%{_mandir}/man*/%{name}*
|
||||
#%exclude %{_mandir}/man1/*ctr.1*
|
||||
|
||||
%files ctr
|
||||
%{_sbindir}/%{realname}-ctr
|
||||
%{_sbindir}/containerd-ctr
|
||||
# TODO: Fix man page generation.
|
||||
#%{_mandir}/man1/*ctr.1*
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user