Accepting request 494718 from Virtualization:containers
Automatic submission by obs-autosubmit OBS-URL: https://build.opensuse.org/request/show/494718 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/runc?expand=0&rev=12
This commit is contained in:
commit
c08cc4e6bb
2
_service
2
_service
@ -8,7 +8,7 @@
|
|||||||
<param name="scm">git</param>
|
<param name="scm">git</param>
|
||||||
<param name="filename">runc</param>
|
<param name="filename">runc</param>
|
||||||
<param name="versionformat">git.%h</param>
|
<param name="versionformat">git.%h</param>
|
||||||
<param name="revision">2f7393a47307a16f8cee44a37b262e8b81021e3e</param>
|
<param name="revision">9c2d8d184e5da67c95d601382adf14862e4f2228</param>
|
||||||
<param name="exclude">.git</param>
|
<param name="exclude">.git</param>
|
||||||
</service>
|
</service>
|
||||||
<service name="recompress" mode="disabled">
|
<service name="recompress" mode="disabled">
|
||||||
|
@ -1,31 +0,0 @@
|
|||||||
From e7b57cb042130edf86506d189734018edc3f2c18 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Mrunal Patel <mrunalp@gmail.com>
|
|
||||||
Date: Tue, 10 Jan 2017 15:13:28 -0800
|
|
||||||
Subject: [PATCH] Ignore cgroup2 mountpoints
|
|
||||||
|
|
||||||
Our current cgroup parsing logic assumes cgroup v1 mounts
|
|
||||||
so we should ignore cgroup2 mounts for now
|
|
||||||
|
|
||||||
Backport: https://github.com/opencontainers/runc/pull/1266
|
|
||||||
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
|
|
||||||
Signed-off-by: Aleksa Sarai <asarai@suse.de>
|
|
||||||
---
|
|
||||||
libcontainer/cgroups/utils.go | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/libcontainer/cgroups/utils.go b/libcontainer/cgroups/utils.go
|
|
||||||
index 8946dd5959e4..c6db0039e654 100644
|
|
||||||
--- a/libcontainer/cgroups/utils.go
|
|
||||||
+++ b/libcontainer/cgroups/utils.go
|
|
||||||
@@ -149,7 +149,7 @@ func getCgroupMountsHelper(ss map[string]bool, mi io.Reader, all bool) ([]Mount,
|
|
||||||
if sepIdx == -1 {
|
|
||||||
return nil, fmt.Errorf("invalid mountinfo format")
|
|
||||||
}
|
|
||||||
- if txt[sepIdx+3:sepIdx+9] != "cgroup" {
|
|
||||||
+ if txt[sepIdx+3:sepIdx+10] == "cgroup2" || txt[sepIdx+3:sepIdx+9] != "cgroup" {
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
fields := strings.Split(txt, " ")
|
|
||||||
--
|
|
||||||
2.12.2
|
|
||||||
|
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:ada7533b8a684ffde5a7b45517573bdae3a501cc3460107a0deb1e290f040bb0
|
|
||||||
size 413492
|
|
3
runc-git.9c2d8d1.tar.xz
Normal file
3
runc-git.9c2d8d1.tar.xz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:d7dda7c4b4d031fd0f32423fc01e5199ef204a0edf1ed3d70992e7e30ea473a2
|
||||||
|
size 413996
|
33
runc.changes
33
runc.changes
@ -1,3 +1,36 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu May 4 19:04:49 UTC 2017 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
- fix the golang requirement to 1.7 to the subpackages
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue May 2 15:49:41 UTC 2017 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
- fix golang requirement to 1.7
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Apr 28 16:16:00 UTC 2017 - jengelh@inai.de
|
||||||
|
|
||||||
|
- Substitute %__-type macro indirections
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Apr 13 16:34:03 UTC 2017 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
- update version to the one required by docker-17.04.0-ce (bsc#1034053)
|
||||||
|
remove ignore_cgroup2_mountpoint.patch . This is already included in
|
||||||
|
the upstream source code.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Apr 12 09:55:28 UTC 2017 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
- Make sure this is being built with go 1.7
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Apr 11 15:37:36 UTC 2017 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
- remove the go_arches macro because we are using go1.7 which
|
||||||
|
is available in all archs
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Mar 29 15:47:52 UTC 2017 - jmassaguerpla@suse.com
|
Wed Mar 29 15:47:52 UTC 2017 - jmassaguerpla@suse.com
|
||||||
|
|
||||||
|
54
runc.spec
54
runc.spec
@ -16,37 +16,19 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
# Check if go_arches is defined in the project configuration
|
|
||||||
# Otherwise, define it here
|
|
||||||
# In order to define it in the project configuration, see
|
|
||||||
#
|
|
||||||
# https://en.opensuse.org/openSUSE:Build%20Service%20prjconf#Macros
|
|
||||||
#
|
|
||||||
# The Macros tag is the one that defines the go_arches variable to be used
|
|
||||||
# in the spec file.
|
|
||||||
# The "define" one is to help the specfile parser of the buildservice
|
|
||||||
# to see what packages are being built. You also want to define it here
|
|
||||||
# for keeping things consistent.
|
|
||||||
|
|
||||||
%{!?go_arches: %global go_arches %ix86 x86_64 aarch64 ppc64le}
|
|
||||||
|
|
||||||
%ifarch %go_arches
|
|
||||||
%define go_tool go
|
%define go_tool go
|
||||||
%else
|
|
||||||
%define go_tool go-6
|
|
||||||
%endif
|
|
||||||
|
|
||||||
# MANUAL: Update the git_version and git_revision
|
# MANUAL: Update the git_version and git_revision
|
||||||
# FIX-OPENSUSE: This will be removed as soon as we move Docker's runC fork into
|
# FIX-OPENSUSE: This will be removed as soon as we move Docker's runC fork into
|
||||||
# a separate package. This whole versioning mess is caused by
|
# a separate package. This whole versioning mess is caused by
|
||||||
# Docker vendoring non-releases of runC.
|
# Docker vendoring non-releases of runC.
|
||||||
%define git_version 2f7393a
|
%define git_version 9c2d8d1
|
||||||
# How to get the git_revision
|
# How to get the git_revision
|
||||||
# git clone ${url}.git runc-upstream
|
# git clone ${url}.git runc-upstream
|
||||||
# cd runc-upstream
|
# cd runc-upstream
|
||||||
# git checkout $git_version
|
# git checkout $git_version
|
||||||
# git_revision=r$(git rev-list HEAD | wc -l)
|
# git_revision=r$(git rev-list HEAD | wc -l)
|
||||||
%define git_revision r2942
|
%define git_revision r2947
|
||||||
%define version_unconverted %{git_version}
|
%define version_unconverted %{git_version}
|
||||||
|
|
||||||
Name: runc
|
Name: runc
|
||||||
@ -58,15 +40,11 @@ Group: System/Management
|
|||||||
Url: https://github.com/opencontainers/runc
|
Url: https://github.com/opencontainers/runc
|
||||||
Source: %{name}-git.%{git_version}.tar.xz
|
Source: %{name}-git.%{git_version}.tar.xz
|
||||||
Patch0: CVE-2016-9962.patch
|
Patch0: CVE-2016-9962.patch
|
||||||
Patch1: ignore_cgroup2_mountpoint.patch
|
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
%ifarch %go_arches
|
# Make sure we require go 1.7
|
||||||
BuildRequires: go >= 1.5
|
|
||||||
BuildRequires: go-go-md2man
|
BuildRequires: go-go-md2man
|
||||||
%else
|
|
||||||
BuildRequires: gcc6-go >= 6.1
|
|
||||||
%endif
|
|
||||||
BuildRequires: libapparmor-devel
|
BuildRequires: libapparmor-devel
|
||||||
|
BuildRequires: golang(API) = 1.7
|
||||||
# Seccomp isn't supported on aarch64.
|
# Seccomp isn't supported on aarch64.
|
||||||
%ifnarch aarch64
|
%ifnarch aarch64
|
||||||
BuildRequires: libseccomp-devel
|
BuildRequires: libseccomp-devel
|
||||||
@ -83,13 +61,10 @@ and has grown to become a separate project entirely.
|
|||||||
|
|
||||||
%package test
|
%package test
|
||||||
Summary: Test package for runc
|
Summary: Test package for runc
|
||||||
|
# Make sure we require go 1.7
|
||||||
Group: System/Management
|
Group: System/Management
|
||||||
%ifarch %go_arches
|
BuildRequires: golang(API) = 1.7
|
||||||
Requires: go >= 1.5
|
|
||||||
Requires: go-go-md2man
|
Requires: go-go-md2man
|
||||||
%else
|
|
||||||
Requires: gcc6-go >= 6.1
|
|
||||||
%endif
|
|
||||||
Requires: libapparmor-devel
|
Requires: libapparmor-devel
|
||||||
# Seccomp isn't supported on aarch64.
|
# Seccomp isn't supported on aarch64.
|
||||||
%ifnarch aarch64
|
%ifnarch aarch64
|
||||||
@ -105,9 +80,6 @@ Test package for runc. It contains the source code and the tests.
|
|||||||
%prep
|
%prep
|
||||||
%setup -q -n %{name}-git.%{git_version}
|
%setup -q -n %{name}-git.%{git_version}
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
%if 0%{?suse_version} > 1320
|
|
||||||
%patch1 -p1
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# Do not use symlinks. If you want to run the unit tests for this package at
|
# Do not use symlinks. If you want to run the unit tests for this package at
|
||||||
@ -132,11 +104,8 @@ export BUILDFLAGS="$BUILDFLAGS -lseccomp"
|
|||||||
%go_tool build "$BUILDFLAGS" -tags "$BUILDTAGS" -x -o %{name}-%{version} github.com/opencontainers/%{name}
|
%go_tool build "$BUILDFLAGS" -tags "$BUILDTAGS" -x -o %{name}-%{version} github.com/opencontainers/%{name}
|
||||||
|
|
||||||
# Build man pages, this can only be done on arches where we can build go-md2man.
|
# Build man pages, this can only be done on arches where we can build go-md2man.
|
||||||
%ifarch %go_arches
|
|
||||||
man/md2man-all.sh
|
man/md2man-all.sh
|
||||||
%endif
|
|
||||||
|
|
||||||
%ifarch %go_arches
|
|
||||||
%check
|
%check
|
||||||
export GOPATH=$HOME/go/src/github.com/opencontainers/runc/Godeps/_workspace:$GOPATH
|
export GOPATH=$HOME/go/src/github.com/opencontainers/runc/Godeps/_workspace:$GOPATH
|
||||||
cd $HOME/go/src/github.com/opencontainers/runc
|
cd $HOME/go/src/github.com/opencontainers/runc
|
||||||
@ -148,10 +117,9 @@ PKG_LIST=$(go list ./... \
|
|||||||
| grep -v 'github.com/opencontainers/runc/libcontainer/user$' \
|
| grep -v 'github.com/opencontainers/runc/libcontainer/user$' \
|
||||||
| grep -v 'github.com/opencontainers/runc/libcontainer/xattr$')
|
| grep -v 'github.com/opencontainers/runc/libcontainer/xattr$')
|
||||||
go test -timeout 3m -tags "$BUILDTAGS" -v $PKG_LIST
|
go test -timeout 3m -tags "$BUILDTAGS" -v $PKG_LIST
|
||||||
%endif
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%{__install} -D -m755 %{name}-%{version} %{buildroot}%{_sbindir}/%{name}
|
install -D -m755 %{name}-%{version} %{buildroot}%{_sbindir}/%{name}
|
||||||
install -d -m755 %{buildroot}/usr/src/runc/
|
install -d -m755 %{buildroot}/usr/src/runc/
|
||||||
cp -avr $HOME/go/src/github.com/opencontainers/runc/* %{buildroot}/usr/src/runc/
|
cp -avr $HOME/go/src/github.com/opencontainers/runc/* %{buildroot}/usr/src/runc/
|
||||||
|
|
||||||
@ -159,10 +127,8 @@ cp -avr $HOME/go/src/github.com/opencontainers/runc/* %{buildroot}/usr/src/runc/
|
|||||||
install -d -m755 %{buildroot}/%{_bindir}
|
install -d -m755 %{buildroot}/%{_bindir}
|
||||||
ln -s /usr/sbin/runc %{buildroot}/%{_bindir}/docker-runc
|
ln -s /usr/sbin/runc %{buildroot}/%{_bindir}/docker-runc
|
||||||
|
|
||||||
%ifarch %go_arches
|
install -d -m755 %{buildroot}%{_mandir}/man8
|
||||||
%{__install} -d -m755 %{buildroot}%{_mandir}/man8
|
install -m644 man/man8/runc*.8 %{buildroot}%{_mandir}/man8
|
||||||
%{__install} -m644 man/man8/runc*.8 %{buildroot}%{_mandir}/man8
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%fdupes %{buildroot}/%{_prefix}
|
%fdupes %{buildroot}/%{_prefix}
|
||||||
|
|
||||||
@ -174,9 +140,7 @@ ln -s /usr/sbin/runc %{buildroot}/%{_bindir}/docker-runc
|
|||||||
%{_sbindir}/%{name}
|
%{_sbindir}/%{name}
|
||||||
%{_bindir}/docker-runc
|
%{_bindir}/docker-runc
|
||||||
|
|
||||||
%ifarch %go_arches
|
|
||||||
%{_mandir}/man8/runc*.8.gz
|
%{_mandir}/man8/runc*.8.gz
|
||||||
%endif
|
|
||||||
|
|
||||||
%files test
|
%files test
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
|
Loading…
Reference in New Issue
Block a user