Compare commits

..

No commits in common. "f366b91720db79fcbed2bf0a6d3dfc6037ad1b5d" and "96b4ec597ff0a56142b17ffad349e82dc8f7da0d" have entirely different histories.

4 changed files with 22 additions and 37 deletions

View File

@ -1,7 +1,7 @@
From ae558584459edd75cd8ae2de9000acba8afd092d Mon Sep 17 00:00:00 2001 From 5108900d343863625ded1e56f2f7dfbc18c30f38 Mon Sep 17 00:00:00 2001
From: Jian Zhang <zhang_jian7@hoperun.com> From: wang--ge <wang__ge@126.com>
Date: Mon, 24 Apr 2023 03:10:21 +0800 Date: Wed, 20 Jul 2022 19:16:50 +0800
Subject: [PATCH] k3s-cni-adaptation Subject: [PATCH] k3s cni adaptation
--- ---
plugins/ipam/host-local/dns.go | 2 +- plugins/ipam/host-local/dns.go | 2 +-
@ -39,7 +39,7 @@ index 1b3975a..ab056ad 100644
import ( import (
"bufio" "bufio"
diff --git a/plugins/ipam/host-local/dns_test.go b/plugins/ipam/host-local/dns_test.go diff --git a/plugins/ipam/host-local/dns_test.go b/plugins/ipam/host-local/dns_test.go
index d7e5c13..9c74521 100644 index 1b87002..837c7d4 100644
--- a/plugins/ipam/host-local/dns_test.go --- a/plugins/ipam/host-local/dns_test.go
+++ b/plugins/ipam/host-local/dns_test.go +++ b/plugins/ipam/host-local/dns_test.go
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
@ -50,7 +50,7 @@ index d7e5c13..9c74521 100644
+package hostlocal_test +package hostlocal_test
import ( import (
"os" "io/ioutil"
diff --git a/plugins/ipam/host-local/host_local_suite_test.go b/plugins/ipam/host-local/host_local_suite_test.go diff --git a/plugins/ipam/host-local/host_local_suite_test.go b/plugins/ipam/host-local/host_local_suite_test.go
index d458f6b..b368b0e 100644 index d458f6b..b368b0e 100644
--- a/plugins/ipam/host-local/host_local_suite_test.go --- a/plugins/ipam/host-local/host_local_suite_test.go
@ -65,7 +65,7 @@ index d458f6b..b368b0e 100644
import ( import (
. "github.com/onsi/ginkgo" . "github.com/onsi/ginkgo"
diff --git a/plugins/ipam/host-local/host_local_test.go b/plugins/ipam/host-local/host_local_test.go diff --git a/plugins/ipam/host-local/host_local_test.go b/plugins/ipam/host-local/host_local_test.go
index b9841ab..610185d 100644 index 5cba3d4..1b3a956 100644
--- a/plugins/ipam/host-local/host_local_test.go --- a/plugins/ipam/host-local/host_local_test.go
+++ b/plugins/ipam/host-local/host_local_test.go +++ b/plugins/ipam/host-local/host_local_test.go
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
@ -100,7 +100,7 @@ index 9983c83..3af4407 100644
} }
diff --git a/plugins/main/bridge/bridge.go b/plugins/main/bridge/bridge.go diff --git a/plugins/main/bridge/bridge.go b/plugins/main/bridge/bridge.go
index dce8568..2b265c0 100644 index 23c1256..49c84bb 100644
--- a/plugins/main/bridge/bridge.go --- a/plugins/main/bridge/bridge.go
+++ b/plugins/main/bridge/bridge.go +++ b/plugins/main/bridge/bridge.go
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
@ -112,7 +112,7 @@ index dce8568..2b265c0 100644
import ( import (
"encoding/json" "encoding/json"
@@ -707,7 +707,7 @@ func cmdDel(args *skel.CmdArgs) error { @@ -693,7 +693,7 @@ func cmdDel(args *skel.CmdArgs) error {
return err return err
} }
@ -135,7 +135,7 @@ index 3e48736..392098e 100644
import ( import (
. "github.com/onsi/ginkgo" . "github.com/onsi/ginkgo"
diff --git a/plugins/main/bridge/bridge_test.go b/plugins/main/bridge/bridge_test.go diff --git a/plugins/main/bridge/bridge_test.go b/plugins/main/bridge/bridge_test.go
index 9a75e64..127cdd1 100644 index 118074e..a0f18fb 100644
--- a/plugins/main/bridge/bridge_test.go --- a/plugins/main/bridge/bridge_test.go
+++ b/plugins/main/bridge/bridge_test.go +++ b/plugins/main/bridge/bridge_test.go
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
@ -222,7 +222,7 @@ index c4e41be..69f547e 100644
import ( import (
"fmt" "fmt"
diff --git a/plugins/meta/portmap/main.go b/plugins/meta/portmap/main.go diff --git a/plugins/meta/portmap/main.go b/plugins/meta/portmap/main.go
index 1e6bdd1..ecfd1bb 100644 index 003d4d6..b5f5b3f 100644
--- a/plugins/meta/portmap/main.go --- a/plugins/meta/portmap/main.go
+++ b/plugins/meta/portmap/main.go +++ b/plugins/meta/portmap/main.go
@@ -23,7 +23,7 @@ @@ -23,7 +23,7 @@
@ -234,7 +234,7 @@ index 1e6bdd1..ecfd1bb 100644
import ( import (
"encoding/json" "encoding/json"
@@ -136,7 +136,7 @@ func cmdDel(args *skel.CmdArgs) error { @@ -135,7 +135,7 @@ func cmdDel(args *skel.CmdArgs) error {
return nil return nil
} }
@ -244,7 +244,7 @@ index 1e6bdd1..ecfd1bb 100644
} }
diff --git a/plugins/meta/portmap/portmap.go b/plugins/meta/portmap/portmap.go diff --git a/plugins/meta/portmap/portmap.go b/plugins/meta/portmap/portmap.go
index b89a9df..5c0ec59 100644 index 8178bfb..763ba12 100644
--- a/plugins/meta/portmap/portmap.go --- a/plugins/meta/portmap/portmap.go
+++ b/plugins/meta/portmap/portmap.go +++ b/plugins/meta/portmap/portmap.go
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
@ -257,7 +257,7 @@ index b89a9df..5c0ec59 100644
import ( import (
"fmt" "fmt"
diff --git a/plugins/meta/portmap/portmap_integ_test.go b/plugins/meta/portmap/portmap_integ_test.go diff --git a/plugins/meta/portmap/portmap_integ_test.go b/plugins/meta/portmap/portmap_integ_test.go
index 2468865..e46990f 100644 index 3e8201e..5d91e08 100644
--- a/plugins/meta/portmap/portmap_integ_test.go --- a/plugins/meta/portmap/portmap_integ_test.go
+++ b/plugins/meta/portmap/portmap_integ_test.go +++ b/plugins/meta/portmap/portmap_integ_test.go
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
@ -309,5 +309,5 @@ index a733fda..163e787 100644
import ( import (
"fmt" "fmt"
-- --
2.33.0 2.27.0

View File

@ -11,12 +11,12 @@
# Used for comparing with latest upstream tag # Used for comparing with latest upstream tag
# to decide whether to autobuild # to decide whether to autobuild
%global built_tag v1.2.0 %global built_tag v1.1.1
%global built_tag_strip %(b=%{built_tag}; echo ${b:1}) %global built_tag_strip %(b=%{built_tag}; echo ${b:1})
Name: %{project}-%{repo} Name: %{project}-%{repo}
Version: 1.2.0 Version: 1.1.1
Release: 4 Release: 1
Summary: Libraries for use by writing CNI plugin Summary: Libraries for use by writing CNI plugin
License: ASL 2.0 License: ASL 2.0
URL: https://github.com/containernetworking/plugins URL: https://github.com/containernetworking/plugins
@ -119,7 +119,7 @@ for d in $PLUGINS; do
if [ -d "$d" ]; then if [ -d "$d" ]; then
plugin="$(basename "$d")" plugin="$(basename "$d")"
echo " $plugin" echo " $plugin"
go build -buildmode pie -compiler gc -tags="rpm_crashtraceback ${BUILDTAGS:-}" -ldflags " -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n') -s -w -linkmode=external -extldflags '%__global_ldflags %{?__golang_extldflags} -Wl,-z,now ' " -a -v -x -o "${PWD}/bin/$plugin" "$@" github.com/containernetworking/plugins/$d go build -buildmode pie -compiler gc -tags="rpm_crashtraceback ${BUILDTAGS:-}" -ldflags "${LDFLAGS:-} -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n') -extldflags '%__global_ldflags %{?__golang_extldflags}'" -a -v -x -o "${PWD}/bin/$plugin" "$@" github.com/containernetworking/plugins/$d
fi fi
done done
@ -192,7 +192,7 @@ VERSIONFLAGS="
" "
TAGS="apparmor seccomp netcgo osusergo providerless" TAGS="apparmor seccomp netcgo osusergo providerless"
STATIC="-extldflags '-static -lm -ldl -lz -lpthread'" STATIC="-extldflags '-static -lm -ldl -lz -lpthread'"
GO111MODULE=off CGO_ENABLED=0 GOPATH=$TMPDIR go build -tags "$TAGS" -buildmode=pie -ldflags "$VERSIONFLAGS $STATIC -s -w -linkmode=external -extldflags '-Wl,-z,relro -Wl,-z,now ' " -o %{_builddir}/cni GO111MODULE=off CGO_ENABLED=0 GOPATH=$TMPDIR go build -tags "$TAGS" -ldflags "$VERSIONFLAGS $LDFLAGS $STATIC" -o %{_builddir}/cni
%install %install
install -d -p %{buildroot}%{_libexecdir}/cni/ install -d -p %{buildroot}%{_libexecdir}/cni/
@ -201,8 +201,8 @@ cp %{_builddir}/cni %{buildroot}%{_libexecdir}/cni/
install -d -p %{buildroot}/%{gopath}/src/github.com/containernetworking/plugins/ install -d -p %{buildroot}/%{gopath}/src/github.com/containernetworking/plugins/
install -dp %{buildroot}%{_unitdir} install -dp %{buildroot}%{_unitdir}
install -p -m 0644 plugins/ipam/dhcp/systemd/cni-dhcp.service %{buildroot}%{_unitdir} install -p plugins/ipam/dhcp/systemd/cni-dhcp.service %{buildroot}%{_unitdir}
install -p -m 0644 plugins/ipam/dhcp/systemd/cni-dhcp.socket %{buildroot}%{_unitdir} install -p plugins/ipam/dhcp/systemd/cni-dhcp.socket %{buildroot}%{_unitdir}
# source codes for building projects # source codes for building projects
%if 0%{?with_devel} %if 0%{?with_devel}
@ -313,21 +313,6 @@ export GOPATH=%{buildroot}/%{gopath}:$(pwd)/vendor:%{gopath}
%changelog %changelog
* Mon Jun 24 2024 wangshuo <wangshuo@kylinos.cn> - 1.2.0-4
- change systemd unit file permission to 644
* Fri Mar 1 2024 luofeng <luofeng13@huawei.com> - 1.2.0-3
- Avoid using C ldflags with Go compiler
* Thu Dec 28 2023 yaoxin <yao_xin001@hoperun.com> - 1.2.0-2
- Rebuild for golang cves: CVE-2023-24534,CVE-2023-24536,CVE-2023-24537 and CVE-2023-24538
* Mon Apr 24 2023 Jian Zhang <zhang_jian7@hoperun.com> - 1.2.0-1
- update to version 1.2.0
* Thu Feb 09 2023 yaoxin <yaoxin30@h-partners.com> - 1.1.1-2
- Add PIE,BIND_NOW,RELRO,STRIP secure compilation options
* Wed Jul 20 2022 Ge Wang <wangge20@h-partners.com> - 1.1.1-1 * Wed Jul 20 2022 Ge Wang <wangge20@h-partners.com> - 1.1.1-1
- update to version 1.1.1 - update to version 1.1.1

BIN
v1.1.1.tar.gz Normal file

Binary file not shown.

Binary file not shown.