Hello community,

here is the log from the commit of package multus for openSUSE:Factory checked 
in at 2019-10-27 13:41:26
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/multus (Old)
 and      /work/SRC/openSUSE:Factory/.multus.new.2990 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "multus"

Sun Oct 27 13:41:26 2019 rev:2 rq:743026 version:3.3

Changes:
--------
--- /work/SRC/openSUSE:Factory/multus/multus.changes    2019-01-24 
14:13:24.923362446 +0100
+++ /work/SRC/openSUSE:Factory/.multus.new.2990/multus.changes  2019-10-27 
13:41:33.157305957 +0100
@@ -1,0 +2,12 @@
+Fri Oct 25 00:04:07 UTC 2019 - MichaƂ Rostecki <[email protected]>
+
+- Update to version 3.3:
+  * This release updates for parameters necessary to properly
+    create a CNI configuration under Kubernetes 1.16, among other
+    recent stability fixes.
+- Add multus-k8s-yaml package which provides the Kubernetes yaml
+  file to run Multus containers.
+- Add patch which fixes the build from tarball:
+  * 0001-build-Allow-to-define-VERSION-and-COMMIT-without-git.patch
+
+-------------------------------------------------------------------

Old:
----
  multus-3.1.tar.xz

New:
----
  0001-build-Allow-to-define-VERSION-and-COMMIT-without-git.patch
  multus-3.3.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ multus.spec ++++++
--- /var/tmp/diff_new_pack.f8j6q6/_old  2019-10-27 13:41:34.333307375 +0100
+++ /var/tmp/diff_new_pack.f8j6q6/_new  2019-10-27 13:41:34.333307375 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package multus
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -12,19 +12,21 @@
 # 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/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
 
+%define commit f4431cd010bbf2d68444f5746ca9ff2eae30fc2a
 
 Name:           multus
-Version:        3.1
+Version:        3.3
 Release:        0
 Summary:        CNI plugin providing multiple interfaces in containers
 License:        Apache-2.0
 Group:          System/Management
 Url:            https://github.com/intel/multus-cni
 Source:         %{name}-%{version}.tar.xz
+Patch0:         0001-build-Allow-to-define-VERSION-and-COMMIT-without-git.patch
 BuildRequires:  golang-packaging
 BuildRequires:  golang(API) >= 1.8
 
@@ -33,15 +35,33 @@
 containers. It allows to use many CNI plugins at the same time and supports all
 plugins which implement the CNI specification.
 
+%package k8s-yaml
+Summary:        Kubernetes yaml file to run Multus containers
+Group:          System/Management
+BuildArch:      noarch
+
+%description k8s-yaml
+Multus is a CNI plugin which provides multiple network interfaces in
+containers. It allows to use many CNI plugins at the same time and supports all
+plugins which implement the CNI specification.
+
+This package contains the yaml file requried to download and run Multus
+containers in a Kubernetes cluster.
+
 %prep
-%setup -q
+%autosetup -p1
 
 %build
-./build
+VERSION=%{version} COMMIT=%{commit} GO111MODULE=off ./build
 
 %install
 install -D -m0755 bin/multus %{buildroot}%{_bindir}/multus
 install -D -m0755 images/entrypoint.sh %{buildroot}%{_bindir}/multus-entrypoint
+install -D -m0644 images/multus-daemonset-crio.yml 
%{buildroot}%{_datadir}/k8s-yaml/multus/multus.yaml
+sed -i \
+    -e 's|image: nfvpe/multus.*|image: 
registry.opensuse.org/devel/kubic/containers/container/kubic/%{name}:%{version}|'
 \
+    -e 's|/entrypoint.sh|multus-entrypoint|g' \
+    %{buildroot}%{_datadir}/k8s-yaml/multus/multus.yaml
 
 %files
 %license LICENSE
@@ -49,4 +69,9 @@
 %{_bindir}/multus
 %{_bindir}/multus-entrypoint
 
+%files k8s-yaml
+%dir %{_datarootdir}/k8s-yaml
+%dir %{_datarootdir}/k8s-yaml/multus
+%{_datarootdir}/k8s-yaml/multus/multus.yaml
+
 %changelog

++++++ 0001-build-Allow-to-define-VERSION-and-COMMIT-without-git.patch ++++++
>From d2a7fc037cff470deac7e5622a77d0526a8dec5c Mon Sep 17 00:00:00 2001
From: Michal Rostecki <[email protected]>
Date: Fri, 25 Oct 2019 09:43:31 +0200
Subject: [PATCH] build: Allow to define VERSION and COMMIT without git

Previously the build script required git to be used and installed which
did not allow to build Multus from a tarball which doesn't contain .git
directory. That made packaging of Multus hard.

Example usage after the change if you do not want to use git:

```
$ VERSION=v3.3 COMMIT=ba33df ./build
```

Signed-off-by: Michal Rostecki <[email protected]>
---
 build | 18 ++++++++++--------
 1 file changed, 10 insertions(+), 8 deletions(-)

diff --git a/build b/build
index 7c6a1bca..16d3c8c8 100755
--- a/build
+++ b/build
@@ -9,16 +9,18 @@ fi
 
 # Add version/commit/date into binary
 # In case of TravisCI, need to check error code of 'git describe'.
-set +e
-git describe --tags --abbrev=0 > /dev/null 2>&1
-if [ "$?" != "0" ]; then
-       VERSION="master"
-else
-       VERSION=$(git describe --tags --abbrev=0)
+if [ -z "$VERSION" ]; then
+       set +e
+       git describe --tags --abbrev=0 > /dev/null 2>&1
+       if [ "$?" != "0" ]; then
+               VERSION="master"
+       else
+               VERSION=$(git describe --tags --abbrev=0)
+       fi
+       set -e
 fi
-set -e
 DATE=$(date --iso-8601=seconds)
-COMMIT=$(git rev-parse --verify HEAD)
+COMMIT=${COMMIT:-$(git rev-parse --verify HEAD)}
 LDFLAGS="-X main.version=${VERSION:-master} -X main.commit=${COMMIT} -X 
main.date=${DATE}"
 export CGO_ENABLED=0
 
-- 
2.16.4

++++++ _service ++++++
--- /var/tmp/diff_new_pack.f8j6q6/_old  2019-10-27 13:41:34.365307413 +0100
+++ /var/tmp/diff_new_pack.f8j6q6/_new  2019-10-27 13:41:34.369307418 +0100
@@ -2,11 +2,11 @@
   <service mode="disabled" name="tar_scm">
     <param name="url">https://github.com/intel/multus-cni</param>
     <param name="scm">git</param>
-    <param name="changesgenerate">enable</param>
+    <param name="changesgenerate">disable</param>
     <param name="filename">multus</param>
     <param name="versionformat">@PARENT_TAG@</param>
     <param name="versionrewrite-pattern">v(.*)</param>
-    <param name="revision">refs/tags/v3.1</param>
+    <param name="revision">refs/tags/v3.3</param>
   </service>
   <service mode="disabled" name="recompress">
     <param name="file">*.tar</param>

++++++ multus-3.1.tar.xz -> multus-3.3.tar.xz ++++++
/work/SRC/openSUSE:Factory/multus/multus-3.1.tar.xz 
/work/SRC/openSUSE:Factory/.multus.new.2990/multus-3.3.tar.xz differ: char 26, 
line 1


Reply via email to