Commit Graph

44 Commits

Author SHA1 Message Date
Patrick Vogelaar
2dc87493ed cni: make ca-certificates a packageconfig
Moving ca-certificates into a packageconfig allows using cni without
installing all the certificates.

Signed-off-by: Patrick Vogelaar <patrick.vogelaar@belden.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-06-04 22:33:25 -04:00
Martin Jansa
3971471c05 metadata: relocation.inc: add whitespace around assignments
With:
https://lists.openembedded.org/g/bitbake-devel/message/17508
there are many WARNINGs from this layer

Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-04-03 17:56:53 +00:00
Martin Jansa
b88da59f0b metadata: src_uri.inc: add whitespace around assignments
With:
https://lists.openembedded.org/g/bitbake-devel/message/17508
there are many WARNINGs from this layer

Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-04-03 17:56:53 +00:00
Bruce Ashfield
0967bf494d cni-plugins: update to -top
Bumping cni-plugins.git to version v1.1.0-353-g35831f3d, which comprises the following commits:

    35831f3d Fix addresses and routes reinserted to the VRF
    e20492f0 DHCP lease maintenance should terminate when interface no longer exists.
    3c224f5b Add a new firewall ingress-policy "isolated"
    bd8da200 host-device: Return interface name in result
    44ec80b7 build(deps): bump the golang group with 2 updates
    6e7fb607 build(deps): bump golang.org/x/sys in the golang group
    7c122fab bridge: Add option to enable port isolation
    e4ca66b4 build: split CI and go.mod version
    abfac4a9 Remove scripts/release.sh because of no longer used (#1137)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-03-24 18:42:34 +00:00
Bruce Ashfield
bf7e72e649 cni-plugins: update to v1.6.1
Bumping cni-plugins.git to version v1.1.0-345-gabfac4a9, which comprises the following commits:

    abfac4a9 Remove scripts/release.sh because of no longer used (#1137)
    eded0afc build(deps): bump the golang group across 1 directory with 3 updates
    41d54859 build(deps): bump alpine in /.github/actions/retest-action
    e8c7d9b9 test: enable unpriv user namespaces
    ba8bc7d0 Bump Go version to 1.23 in scripts/release.sh (#1123)
    7f756b41 portmap: fix iptables conditions detection
    3ffc42cd build(deps): bump the golang group across 1 directory with 7 updates
    6de8a985 ipmasq: fix nftables backend
    9296c5f8 portmap: fix nftables backend
    fec2d626 Pass status along ipam update
    a4fc6f93 feat(dhcp): Cancel backoff retry on stop
    d61e7e5e fix(dhcp): can not renew an ip address
    e4950728 build(deps): bump golang.org/x/sys in the golang group
    93d197c4 VRF: Wait for the local/host routes to be added
    c52e02bc add problem hint
    24b0bf96 make test working again
    d44bbf28 Revert "Merge pull request #921 from oOraph/dev/exclude_subnets_from_traffic_shapping2"
    8ad03619 resolve merge conflicts
    8324a2e5 build(deps): bump the golang group across 1 directory with 2 updates
    a4b80cc6 host-device: use temp network namespace for rename
    3a49cff1 Fix txqueuelen being accidentally set to zero
    c11ed487 Ignore link-local routes in SBR tests
    fa737f82 build(deps): bump the golang group with 3 updates
    e5df283a ci, go.mod: bump to go 1.23 (#1094)
    cc8b1bd8 dhcp: Add priority option to dhcp.
    03712a57 .github: add check to verify vendor directory
    01a94e17 Add nftables backend to portmap
    3d1968c1 Fix portmap unit tests
    a3ccebc6 Add a backend abstraction to the portmap plugin
    61d07864 Add nftables implementation of ipmasq
    729dd23c Vendor nftables library, add utils.SupportsIPTables and utils.SupportsNFTables
    a6d6efa5 Use of Scope for routes in IPAM
    01b3db8e SBR: option to pass the table id (#1088)

Bumping flannel-cni-plugin.git to version v1.6.0-flannel1-19-gcc21427, which comprises the following commits:

    eca5d1d Bump alpine from 20240923 to 20250108
    055b015 Bump github.com/containernetworking/plugins from 1.6.1 to 1.6.2
    2f6a5c2 Bump github.com/onsi/gomega from 1.36.0 to 1.36.1
    7838b98 Bump alpine from 20240807 to 20240923
    9b7cc09 Bump github.com/containernetworking/plugins from 1.6.0 to 1.6.1
    773a5f0 Bump github.com/onsi/gomega from 1.35.1 to 1.36.0
    4a32784 Call Unmountns in addition to calling ns.Close()
    1da6802 Bump to 1.23.3 and cni-plugins 1.6.0
    8453685 Bump github.com/onsi/ginkgo/v2 from 2.21.0 to 2.22.0
    5ee8096 Bump github.com/onsi/ginkgo/v2 from 2.20.2 to 2.21.0
    d3a492d Bump github.com/onsi/gomega from 1.34.2 to 1.35.1
    d3c964a Bump github.com/containernetworking/plugins from 1.5.1 to 1.6.0
    b691133 Bump github.com/onsi/gomega from 1.34.1 to 1.34.2

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2025-01-17 19:17:09 +00:00
Bruce Ashfield
e490dc5071 cni: make cnitool more readily available
Having cnitool available on the path helps usability.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-11-15 19:50:00 +00:00
Bruce Ashfield
9f88821d80 cni: rrecommend iptables and iproute
This aren't needed for all plugins, but are required
for others. So we make them a rrecommends to ensure
they are more often than not installed with the main
package.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-11-15 19:50:00 +00:00
Bruce Ashfield
4d79636aac cni: update to v1.2.3
Bumping cni to version v0.8.0-307-g4c9ae43, which comprises the following commits:

    692efbd libcni: set both GC valid attachment keys
    6a68851 SPEC: use correct GC field name.
    587837e libcni: remove use of Masterminds/semver
    2c926b5 SPEC: add warning about preserving shared resources for GC
    9d422db Fix faulty json.Marshal behavior for embeds types.NetConf
    c283314 libcni: implement disableGC
    1125b83 Spec: add disableGC flag
    529bccb GetCachedAttachments should ignore missing directories
    267db70 build(deps): bump github.com/onsi/ginkgo/v2 in the golang group
    6ef5715 libcni: always delete the cache on conflist for CNI DEL
    02ffd01 build(deps): bump alpine in /.github/actions/retest-action
    1e7858f supplement ns building files for darwin os
    52babb0 Update golangci-lint to v1.57.1
    f5e23f5 build(deps): bump golangci/golangci-lint-action from 4 to 6
    e34763a build(deps): bump the golang group with 2 updates
    3d7be1b build(deps): bump the golang group across 1 directory with 2 updates
    047255e spec: remove "-dev" tag
    dd65e2d add version to cni interface
    0036b62 cnitool CNI 1.1.0 support
    a67dabb use errors package in golang v20 to join multiple errors
    f846cb7 build(deps): bump the golang group with 2 updates
    829ae61 Update golang to active supported version
    56f11c6 types: add ValidAttachments to "base" NetConf struct
    8eb1091 pkg/invoke: add DelegateStatus, DelegateGC methods
    2e9688f Docs: remove obsolete information about building release artifacts
    c45adb6 Add MTU to CNI result
    2d04079 tolerate invalid cni caches for deletion
    00576a2 Scope property as int pointer
    a4d4a0d Add Scope property for routes
    163db33 Add socket path and pciid to CNI interface result
    94fc2b1 Table ID property as int pointer
    3c4079b Add table ID property for routes

Bumping cni-plugins.git to version v1.1.0-313-g01b3db8e, which comprises the following commits:

    01b3db8e SBR: option to pass the table id (#1088)
    06ba001d Update containernetworking/cni to v1.2.3 for GC
    deb8ef63 Update go-iptables
    bdb6814f macvlan: add bcqueuelen setting
    07bd3250 build(deps): bump the golang group across 1 directory with 4 updates
    d924f05e build: update github.com/vishvananda/netlink to 1.3.0
    6269f399 Fix unnecessary retrying when the link is down in dhcp.
    675ca922 test: bump go version
    30078e1c .github: fix double-triggering CI
    352c8b7a Change chown to change current dir as well
    d5f9ad99 build(deps): bump the golang group with 2 updates
    508c94ca build(deps): bump the golang group across 1 directory with 3 updates
    434e9b9e Fix release tar images' owner to root
    0e87bccf build(deps): bump alpine in /.github/actions/retest-action
    14cad164 build(deps): bump the golang group with 2 updates
    5c95925a build(deps): bump golangci/golangci-lint-action from 4 to 6
    dc8b8289 build(deps): bump the golang group across 1 directory with 4 updates
    9397270f dependabot: don't automatically update cni packages
    3656c69d build: bump release go version
    427af863 Fix release script in github action
    ada798a3 fix: close resolv.conf
    eb49a034 ip: include peer name in error message
    717b4337 build(deps): bump golang.org/x/net from 0.20.0 to 0.23.0
    ccc1cfaa Simplify unit test
    78ebd8bf minor case change
    c666d140 bandwidth plugin: split unit tests in several files
    ab0b386b bandwidth: possibility to specify shaped subnets or to exclude some from shaping
    52da39d3 bandwidth: possibility to exclude some subnets from traffic shaping
    6f05dc32 build(deps): bump the golang group with 1 update
    c4646743 build(deps): bump the golang group with 4 updates
    ba5bdafe Use temporary name for netdevice when moving in/out of NS
    d34720b5 Support DeviceID on Auxiliary Bus
    8a3014f2 build(deps): bump actions/checkout from 3 to 4
    352e0512 Update golangci-lint-action package to v4
    9c016b5d Rename unused variables to resolve lint warnings
    394ab0d1 build(deps): bump the golang group with 5 updates
    47373d26 build(deps): bump actions/setup-go from 3 to 5
    2bae9b67 Update to Go v1.22 in CI and release
    cb244060 Fix version of golangci-lint
    8b2b1d20 Add github action to build binaries for each platform at release
    7e131a00 bridge: Enable disabling bridge interface
    133a764c build(deps): bump alpine in /.github/actions/retest-action
    e6099fb8 build(deps): bump actions/setup-go from 4 to 5

Bumping flannel-cni-plugin.git to version v1.5.1-flannel3, which comprises the following commits:

    b691133 Bump github.com/onsi/gomega from 1.34.1 to 1.34.2
    ce2b072 Bump github.com/onsi/ginkgo/v2 from 2.20.1 to 2.20.2
    3bcc5a8 Bump go to 1.22
    c5e4f4b Bump github.com/containernetworking/cni from 1.2.1 to 1.2.3
    8a9a79d Bump github.com/onsi/ginkgo/v2 from 2.19.0 to 2.20.1
    67765da Bump alpine from 20240606 to 20240807
    6fe8827 Bump alpine from 20240329 to 20240606
    3838eea Bump Go version
    b60152b Bump github.com/containernetworking/cni from 1.2.0 to 1.2.1
    957ab8a Bump github.com/containernetworking/plugins from 1.5.0 to 1.5.1
    9aa349b Bump github.com/containernetworking/cni from 1.1.2 to 1.2.0
    3260428 Bump github.com/onsi/ginkgo/v2 from 2.17.2 to 2.19.0
    aab0543 Bump github.com/containernetworking/plugins from 1.4.1 to 1.5.0
    5eaab45 Bump github.com/onsi/gomega from 1.33.0 to 1.33.1
    9864944 Bump github.com/onsi/ginkgo/v2 from 2.17.1 to 2.17.2
    2e28128 Bump github.com/onsi/gomega from 1.32.0 to 1.33.0
    85206d1 Bump Go and plugins version
    edfb6ce Bump alpine from 20231219 to 20240329
    b3c6e9f Bump github.com/onsi/gomega from 1.31.1 to 1.32.0
    6eec09d Bump google.golang.org/protobuf from 1.31.0 to 1.33.0
    37b5025 Bump github.com/onsi/gomega from 1.30.0 to 1.31.1
    0a6e942 Bump alpine from 20230901 to 20231219
    92c06f2 Bump github.com/containerd/containerd from 1.6.23 to 1.6.26
    da2c8ca Create dependabot.yml
    28a4dca fix doc
    78381fe fix wrong doc
    45a7bb3 Update to plugins v1.4.0
    9bd5e58 upload release artifact on the release page
    f58497e set CGO_ENABLED=1 when GOARCH=amd64
    8d52b1f  simplify the packaging and releasing of flannel-cni
    9f9ea24 Fix typo in flannel_linux_test.go
    6214abd update Githb actions to stay up to date
    1dfe98d Add support for riscv64
    f50cfdc Set as latest the released image
    6464faa Fixed release artifacts path

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-10-03 01:28:52 +00:00
Bruce Ashfield
3653862e5b cni: adapt SRC_URI to include destsuffix=${GO_SRCURI_DESTSUFFIX}
As of commit cc4ec43a2b657fb4c58429ab14f1edc2473c1327 [go: Drop fork
of unpack code, mandate GO_SRCURI_DESTSUFFIX] we require this
variable in our go recipes.

We also must adjust to UNPACKDIR changes which requires rework
of the directories for the clones and source layout.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-05-29 13:16:56 +00:00
Changqing Li
7ccaa4ac22 cni: pass BuildVersion info to avoid runtime warning
The default value of BuildVersion is 'unknown' and it
requires an override at link time to embed such version
info into binary.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-05-02 18:22:42 +00:00
Bruce Ashfield
f1892e34f6 cni: convert recipe to vendor fetched format
The latest update to the CNI recipe brings in more vendor
dependencies.

To fix the build, we convert it to the same format as other
vendored recipes in meta-virtualiation. The files in the
udpated a recipe were created via:

  ./scripts/oe-go-mod-autogen.py --repo https://github.com/containernetworking/cni.git --rev b62753aa2bfa365c1ceaff6f25774a8047c896b5

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-03-15 17:17:19 +00:00
Bruce Ashfield
2a217f7e91 cni: update to v1.2.0-rc0
Bumping cni to version v0.8.0-237-gb62753a, which comprises the following commits:

    d1276f1 Add Marshal function in Result/NetConf to omit empty value
    a6a9891 libcni: implement version negotiation
    1362169 go get github.com/Masterminds/semver/v3
    f51f8ea SPEC: add version negotiation
    f8d7b81 build(deps): bump github.com/containernetworking/plugins
    6bac4ee build(deps): bump alpine in /.github/actions/retest-action
    91db252 build(deps): bump actions/setup-go from 4 to 5
    0e4c0e2 cleanup: update references, make links relative
    4caff13 libcni, skel: implement STATUS
    b9a9324 build(deps): bump the golang group with 1 update
    4a0bccb describe mtu, advmss, priority attributes of route object in specification
    efffbee Add route attributes - MTU, AdvMSS, Priority
    cd1b855 build(deps): bump the golang group with 2 updates
    6ed65ac Fix if condition for netns override
    f67e207 use replace directive for github.com/containernetworking/cni
    cfdc39b build(deps): bump the golang group with 1 update
    509c490 spec: STATUS wording
    0c68fe1 build(deps): bump the golang group with 2 updates
    29ba516 Upgrade debug module go version to 1.18
    b7d75ff Define Makefile with golangci-lint
    4683716 enable gocritic linter
    91629d5 dependabot: batch updates
    e86c9ca resume and complete gc impl
    02155e0 skel: add gc support
    d9f1e67 wip GC implementation -- spec
    8fdefe9 noop: support command log file
    004b09b Add Tomofumi Hayashi as a CNI maintainer
    11077bc build(deps): bump actions/checkout from 3 to 4
    0021b93 SPEC: fix misspelled word
    3072cfe SPEC: add wording for GC verb
    837171b Add AWS VPC CNI for 3P list
    215259b fix kubernetes document url in readme
    4a096f6 pkg/types: explicitly import all versions
    a899051 libcni: add version v1.1.0
    c768dcb SPEC: bump version to v1.1.0-dev
    a8fdbf9 build(deps): bump alpine in /.github/actions/retest-action

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>

cni-plugins: update to 1.4.0

Bumping cni-plugins.git to version v1.1.0-232-gb6a0e0bc, which comprises the following commits:

    e6099fb8 build(deps): bump actions/setup-go from 4 to 5
    82542170 build(deps): bump the golang group with 2 updates
    d7082175 Bump to golang:1.21-alpine in release.sh
    a4cbf13a Add CNI_NETNS_OVERRIDE for upcoming CNI change
    6cac5d60 build(deps): bump the golang group with 3 updates
    f90ac41a revert some code in pr 962
    5280b4d5 bridge: fix spelling
    495a2cbb bridge: remove useless firstV4Addr
    8c59fc1e bridge: remove useless check
    1079e113 Add ndisc_notify in ipvlan for ipv6 ndp
    999ca157 macvlan: enable ipv6 ndisc_notify
    0b1a96ff build(deps): bump google.golang.org/grpc from 1.50.1 to 1.56.3
    28c5faee build(deps): bump the golang group with 3 updates
    aacae5c0 dependabot: batch updates
    6b787612 fix workflow warnings
    37531cda fix lint errors
    845ef62b macvlan cmdDel: replace the loadConf function with json.unmarshal
    691186ca build(deps): bump github.com/onsi/gomega from 1.27.8 to 1.28.0
    19e5747a build(deps): bump golang.org/x/net from 0.10.0 to 0.17.0
    18172539 build(deps): bump github.com/Microsoft/hcsshim from 0.9.9 to 0.11.1
    61fa9636 build(deps): bump golang.org/x/sys from 0.10.0 to 0.13.0
    33ccedc6 Create IPAM files with 0600 permissions
    853b82d1 build: Use POSIX sh for shell scripts
    d216b0c3 build(deps): bump actions/checkout from 3 to 4
    5f25a93a ci(lint) extend timeout to 5 min
    7c11d486 build(deps): bump github.com/coreos/go-iptables from 0.6.0 to 0.7.0
    c1a7948b vrf: fix route filter to use output iface

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-03-15 17:17:19 +00:00
Changqing Li
d1d50f9861 cni: clean dir ${B}/plugins before do_compile
Clean dir ${B}/plugins before do_compile to avoid cni generated binaries
like /usr/libexec/cni/bridge has wrong dynamic linker path and reports
error like: /usr/libexec/cni/bridge: no such file or directory".

Reproduce steps:
1. bitbake cni
2. enable usrmerge feature in local.conf
3. bitbake cni

After step 2, GOBUILDFLAGS changed,
"-I /lib64/ld-linux-aarch64.so.1" -> "/usr/lib/ld-linux-aarch64.so.1"

But "go build" seems only check if the cached packagefile changed, since
all not changed, the dynamic linker still use the old one, maybe go
build should improve this.

Clean dir ${B}/plugins to trigger rebuild of the binaries here.

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-11-06 16:21:12 +00:00
Bruce Ashfield
e037f1d534 cni: update to v1.1.2
Bumping cni to version v0.8.0-171-gca96f4c, which comprises the following commits:

    a899051 libcni: add version v1.1.0
    c768dcb SPEC: bump version to v1.1.0-dev
    e34f9d2 build(deps): bump github.com/onsi/ginkgo/v2 from 2.9.7 to 2.11.0
    2161bf8 build(deps): bump github.com/onsi/ginkgo/v2 from 2.9.4 to 2.9.7
    b6608f8 build(deps): bump github.com/onsi/ginkgo/v2 from 2.9.2 to 2.9.4
    15612fc build(deps): bump github.com/onsi/ginkgo/v2 from 2.8.0 to 2.9.2
    10ec024 build(deps): bump actions/setup-go from 3 to 4
    db718fc build(deps): bump github.com/containernetworking/plugins
    9302e5f enable more linters
    05f80e4 3rd party plugins - spiderpool
    aef15f6 Porting over getCachedNetworkInfo routine from cri-o
    435fcb1 add meeting link to README
    d4c7848 ci(lint): enable errorlint linter
    1ffb655 fix wrong notes for ValidateInterfaceName()
    420e594 Extend capabilities with cgroup path
    024c57f build(deps): bump github.com/vishvananda/netns from 0.0.2 to 0.0.4
    121798a build(deps): bump github.com/onsi/ginkgo/v2 from 2.7.0 to 2.8.0
    da8672c ci(lint): setup lint job
    8ac5c8a build(deps): bump github.com/onsi/ginkgo/v2 from 2.6.1 to 2.7.0
    5fa3464 build(deps): bump github.com/vishvananda/netns from 0.0.1 to 0.0.2
    45761d9 update github.com/vishvananda/netns to v0.0.1
    aeb1d8e build(deps): bump github.com/containernetworking/plugins
    dd2d40c build(deps): bump github.com/containernetworking/cni in /plugins/debug
    9795493 Update dependabot.yml
    0a26996 build(deps): bump alpine in /.github/actions/retest-action
    cc03617 build(deps): bump github.com/onsi/gomega from 1.17.0 to 1.24.2
    55be4cc Create dependabot.yml
    f024754 refactor: move from io/ioutil to io and os packages

Bumping cni-plugins.git to version v1.1.0-181-g9d9ec6e3, which comprises the following commits:

    c1a7948b vrf: fix route filter to use output iface
    8e69e38d test_linux.sh: Do not fail if called twice
    0a100e5d meta: firewall: Fix firewalld test with non-abstract sockets
    3eb775c5 plugins: meta: portmap: Implement a teardown() fast path
    719f60bb utils: iptables: Use go-iptables' ChainExists()
    2ba7f160 spoofcheck: Make use of go-nft's ApplyConfigEcho()
    ba41448f test: install binaries using `go install`
    13fd3de7 build(deps): bump golang.org/x/sys from 0.9.0 to 0.10.0
    470eee13 [tuning]add ability to set tx queue len
    2216cff9 build(deps): bump github.com/onsi/ginkgo/v2 from 2.9.2 to 2.11.0
    83029bef build(deps): bump golang.org/x/sys from 0.7.0 to 0.9.0
    48aa2f4e Fix race conditions in DHCP test
    ca12d49b Add routes propagation for VRF plugin
    0389a290 github: remove stale issue cleanup
    edab9efd tap: allow for a tap device to be created as a bridge port
    1b2dc7c2 build(deps): bump alpine in /.github/actions/retest-action
    7e918412 [sbr]: Ignore LinkNotFoundError during cmdDel
    99b475ab build(deps): bump github.com/Microsoft/hcsshim from 0.9.8 to 0.9.9
    d8fc886b Bump to golang 1.20 to pick up go1.19.6 / go1.20.1 CVE fixes
    c347755f Fix ValidateExpectedRoute with non default routes and nil GW
    5b7a263e tuning: fix cmdCheck when using IFNAME
    135292e0 bridge, del: timeout after 55 secs of trying to list rules
    7dcd738d bridge, spoofcheck: only read the prerouting chain on CNI delete
    83fe87c5 build: consume specific tables/chains via go-nft
    090af7db bridge: add vlan trunk support
    10ddd9e4 enable govet and unparam linters
    435ef223 build(deps): bump golang.org/x/sys from 0.6.0 to 0.7.0
    821982da Add parameter to disable default vlan
    cac8230e bridge, spoof check: remove drop rule index
    bc5f3def go.mod: bump all deps
    7bbd4d19 linter: fix ginkgolinter errors
    6c0d73ec Fix wastedassign linter errors
    086f7eb7 build(deps): bump actions/stale from 7 to 8
    d71d0f2d Fix revive linter errors
    00e0d3b7 build(deps): bump actions/setup-go from 3 to 4
    2fb0efe8 enable durationcheck,  predeclared, unconvert, unused and wastedassign linters
    c0fe3b7b remove govet and gofmt from test_linux.sh
    09f36a29 enable ginkgolinter linter
    a02bf4b4 enable revive linter
    79f52468 enable gocritic linter
    5a7619c0 enable gosimple linter
    709e775b enable  nonamedreturns linter
    3a04eb00 enable ineffassign linter
    16ba4222 enable contextcheck linter
    177e0bf2 enable staticcheck linter
    d12b81de ci(lint): setup golangci-lint
    6223674f ci(lint): setup yamllint linter Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
    9ee4d322 Fix overwritten error var in getMTUByName
    2d1005ec Update tests to utilize ginkgo/v2
    23c21341 Update ginkgo to v2 in go.mod, go.sum, vendor
    01d00314 Tap plugin
    9a2f7633 build(deps): bump github.com/onsi/gomega from 1.24.2 to 1.26.0
    29e64861 build(deps): bump golang.org/x/sys from 0.4.0 to 0.5.0
    fb5d195f Only check ipv6 when an IPv6 is configured
    ac7cf825 Add support for in-container master for macvlans
    c798f809 Add support for in-container master for ipvlan
    9fa80036 Add support for in-container master for vlans
    2c4c27eb bridge: re-fetch mac address
    0fc229df Update Allocate method to reuse lease if present
    ec924a4b build(deps): bump github.com/safchain/ethtool to v0.2.0
    20a92ff3 build(deps): bump golang.org/x/sys from 0.3.0 to 0.4.0
    fa2ed0fd Add IPv6 support for AddDefaultRoute
    b769956c build(deps): bump github.com/containernetworking/cni from 1.0.1 to 1.1.2
    df141fc7 build(deps): bump github.com/coreos/go-systemd/v22 from 22.3.2 to 22.5.0
    35047644 build(deps): bump github.com/onsi/ginkgo from 1.16.4 to 1.16.5
    352f181f build(deps): bump alpine in /.github/actions/retest-action
    91b1a0e3 build(deps): bump github.com/godbus/dbus/v5 from 5.0.4 to 5.1.0
    648dd2e1 build(deps): bump github.com/vishvananda/netlink
    615420fa build(deps): bump github.com/alexflint/go-filemutex from 1.1.0 to 1.2.0
    90ed30a5 build(deps): bump github.com/Microsoft/hcsshim from 0.8.20 to 0.9.6
    020b8db6 build(deps): bump github.com/onsi/gomega from 1.15.0 to 1.24.2
    c5e81e3c Update dependabot.yml
    3be17f4a build(deps): bump actions/checkout from 2 to 3
    f64652fa build(deps): bump actions/stale from 4 to 7
    edfd2274 build(deps): bump actions/setup-go from 2 to 3
    d7efab18 Update dependabot.yml
    12471312 Update dependabot.yml
    c1e2be27 ci(deps): setup dependabot
    fd9408bc Fix tuning path validation
    9dc2ed2c Update email to gmail
    6b30e290 Update portmap test's iptables error check
    1a6f4789 Remove references to io/ioutil package
    63a6dbcf fix bug on getting NextIP of addresses with first byte 0
    198ab129 Fix path substitution to enable setting sysctls on vlan interfaces
    0463fd19 support masquerade all config
    87c3643d host-local: remove unused Release(ip) from type Store interface
    f89a0057 Cleanup Socket and Pidfile on exit
    7fcf8e48 dummy: Create a Dummy CNI plugin that creates a virtual interface.
    c78e1e46 Use the same options for acquiring, renewing lease
    9f4090da bridge: update vlanFiltering variable to make code more readable
    f1aa6c26 ci: only rerun failed jobs on `/retest`
    bf4068e1 build: support riscv64
    7c452c77 Check for duplicated sysctl keys
    f8917228 Update github.com/vishvananda/netlink to v1.2.0-beta
    a70e87c3 bridge: support IPAM DNS settings
    0a0853a7 Bump to go 1.18
    8b8825bc    V2 API support for win-overlay CNI
    e3d563b0 bug: return errors when iptables and ip6tables are unusable
    e952f16c github: ignore issues with "keep" label from stale closing
    5ad4fcf8 Make description for `static` plugin more exact
    57c1cb50 workflow: add something to auto-close stale PRs
    7a989794 ipam/dhcp: Fix client id in renew/release
    7aa07efe call ipam.ExceDel after clean up device in netns fix #666
    96c3af81 Add sysctl allowlist

Bumping flannel-cni-plugin.git to version v1.1.2-13-g6464faa, which comprises the following commits:

    6464faa Fixed release artifacts path
    bff4cf9 FIx bug in actions/download-artifact@v3
    ffabfad Update go.mod
    088da1a Use writeAndSyncFile instead of just write
    04854df Update ginkgo to v2
    eb47c95 Upgrade go version to 1.20.5
    6f13a99 Fix some errors thrown by lint tool
    3511c0a Updated Docker registry
    f271951 only include the binary file for one architecture in the release archive
    1537c92 update of GH workflows

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-08-24 01:38:21 +00:00
Chen Qi
0cc4d01dcb cni: fix textrel QA issue
When building cni, we get textrel QA issue like below:

  cni: ELF binary /usr/libexec/cni/macvlan has relocations in .text

The problem could be solved by adding '-buildmode=pie' to ${GO}.

In go.bbclass, this flag is added to GOBUILDFLAGS conditionally,
that is, if the arch is not mips nor riscv32, this '-buildmode=pie'
is added to GOBUILDFLAGS. So make use of that.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-07-05 23:46:19 -04:00
Bruce Ashfield
a969b554a6 cni: update to 1.1,2
Bumping cni to version v0.8.0-126-gf024754, which comprises the following commits:

    f024754 refactor: move from io/ioutil to io and os packages
    e18f632 Update email to gmail
    58488a6 Upgrade GitHub actions packages to resolve NodeJS 12 warnings
    62709e0 Removed loxilight as it is not supported anymore
    76aaefb libcni: handle string-type disableCheck values
    04dce8c testhelpers: use `go mod tidy` to ensure all necessary dependencies before building
    be9139d cdc: update email
    dc22d04 go.mod: bump to go1.18
    6996769 github: bump go version to v1.19
    08fb460 go fmt
    dbf33e2 fix 714-plugin add netns validation reinforcement
    8dba382 libcni: add specific type for CHECK not supported
    a710a7b Updated Calico project link
    1c7c696 Fix successfully unmarshalled nil raw result
    58b77bd spec: fix format
    55fe94e invoke: if Result CNIVersion is empty use netconf CNIVersion
    99eac24 cnitool: address golint error

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>

cni-flannel: update to 1.1,2

Bumping flannel-cni-plugin.git to version v1.1.2-2-ga2398ab, which comprises the following commits:

    1537c92 update of GH workflows
    acb770d Make sure the CNI delete function does not fail when the json config is wrong
    e541b70 Allow multiple flannel networks and upgrade to Go 1.19.2
    6e8bb11 upgrade cni and plugins deps
    076c446 add mips64le dockerfile

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-01-10 13:58:07 -05:00
Bruce Ashfield
f5b7922278 cni: reproducible builds: pass -trimpath
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-09-13 13:13:52 -04:00
Andrei Gherzan
cca772a457 cni: Use gcc-based toolchain
clang-based builds are still broken due to:
https://github.com/llvm/llvm-project/issues/53999

Signed-off-by: Andrei Gherzan <andrei.gherzan@huawei.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-08-03 23:18:32 -04:00
Bruce Ashfield
cd0a2c949a cni/plugins: update to 1.1.1
Bumping cni-plugins.git to version v1.1.1, which comprises the following commits:

    b1782e5 ipam/dhcp: Fix client id in renew/release
    b03deb6 call ipam.ExceDel after clean up device in netns fix #666

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-06-03 09:32:13 -04:00
Bruce Ashfield
a40e168766 cni: update to 1.1.0
Bumping cni to version v0.8.0-102-g940e662, which comprises the following commits:

    99eac24 cnitool: address golint error
    1054f8e libcni: handle empty version when parsing version
    54f1587 Switch to ginkgo/v2
    aba8f8b add security heading to README
    4b46fe6 Maintainers: add Mike Zappa
    2f6d8b1 introduce hybridnet to thrid-party plugins
    48fac6a Update README.md
    798e63d Updated README.md to include Netlox loxilight CNI

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-06-03 09:32:13 -04:00
Bruce Ashfield
654f8d02a6 cni: fix protocol argument typo
The newly added flannel_plugin had a typo of protcol, so we add our
missing 'o' and fix the uri parameter.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-04-11 08:13:16 -04:00
Bruce Ashfield
589391db27 cni: add flannel plugin from separate repository
We have flannel users! It was noted that flannel is no longer part
of the main cni-plugins repo, but is instead hosted in a standalone
location.

We add the new repository, its SRCREV and drop it back where it
can be built and packaged in the same way as it previously was.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-04-08 13:36:28 -04:00
Bruce Ashfield
0f7a2e57d6 cni: update to v1.0.1
Bumping cni to version v0.8.0-90-g35efaab, which comprises the following commits:

    3e49ce1 Fix incorrect pointer inputs to `json.Unmarshal`
    b92c836 fix version of cni v0.8.1 does not have a directory of github.com/containernetworking/cni/pkg/types/100 refer to https://github.com/containernetworking/cni/tree/v0.8.1/pkg/types
    269bf61 Spec: Container runtime shall tear down namespaces
    48fac6a Update README.md
    798e63d Updated README.md to include Netlox loxilight CNI
    9070cb3 documentation: update Multus link in README.md to point to the k8snetworkplumbingwg repository
    21cd5f0 [exec-plugins]: support plugin lists
    c362597 skel: remove superfluous err nil check in (*dispatcher).pluginMain
    42f2474 Remove Gabe Rosenhouse as maintainer
    2e4887b skel: print out CNI versions supported in help text.
    c7f5f70 pkg/version: add VersionsFrom function
    5608690 spec: bump to 1.0.0
    30e06a8 Docs: bump spec version information
    a956246 docs: revise cnitool docs
    63a3bca wrap returned errors
    b277ec1 docs: correct the extension name of the configuration file
    34a8a46 chore: standardize documentation on IP assignment
    76bf3de types: ensure empty CNIVersion always creates/converts to 0.1.0
    4feedb9 Add breadcrumbs for CNI.go
    57cf1ce types/create: add CreateFromBytes()
    4fdc5f6 chore: support both value type and pointer type in LoadArgs
    f30a824 Remove Bryan Boreham as maintainer
    c63d850 Add debug plugin to help debugging/troubleshooting (#818)
    9546b70 spec: Some minor corrections
    3a13f68 Spec: Bring 1.0's treatment of "args" in line with 0.4.0
    c92642b upgrade kube-ovn new github site
    67ec904 Fix typo in SPEC.md
    0555966 typos correct
    8ad568b Rewrite spec.md for 1.0.0
    0016917 Adding reference to Azure CNI as 3rd party plugin in readme
    ad59be0 types/040: add testcase for <= 0.2.0 Result requirement of one or more IPs
    e32b586 remove build badges from homepage
    296290a Switch from Travis to GH Actions
    a199e6a go fmt
    c735780 Markups.
    b678c26 Log out the plugin name on ADD/DEL failure.

cni-plugins: update to 1.1,0

Bumping cni-plugins.git to version v1.1.0-6-gb8a10bb, which comprises the following commits:

    7a98979 ipam/dhcp: Fix client id in renew/release
    7aa07ef call ipam.ExceDel after clean up device in netns fix #666
    96c3af8 Add sysctl allowlist
    08d0f33 portmap: fix checkPorts result when chain does not exist
    dca23ad portmap: fix bug that new udp connection deletes all existing conntrack entries
    ba47b49 Enhanced dad set to 1
    2be2960 Add boolean to enable/disable dad
    8ede7ee Disable DAD for container side veth
    22dd6c5 firewall: support ingressPolicy=(open|same-bridge) for isolating bridges as in Docker
    90e8e1f Fix host-device gofmt
    3b2afc9 host-device: Bring interfaces up after moving into container
    9649ec1 pkg/ns: use file system magic numbers from golang.org/x/sys/unix
    0c12d8a gofmt
    152e7a4 go mod tidy
    4319bc4 build: bump to go 1.17
    7a55617 Remove arp notify setting per comment
    5d073d6 plugins: replace arping package with arp_notify
    67110e0 fix #685
    1324428 Ran go fmt so tests would pass
    fd4c335 Fixed DHCP problem that broke when fast retry was added.
    c9d0423 dhcp ipam: adjust retry mechanism
    547a516 add ipam tests for dpdk device
    3033fd2 add ipam support for dpdk device
    d5a6569 ipvlan: Send Gratuitous ARP after IPs are set
    27fdec5 dhcp ipam: fix client id
    a1051f3 dhcp ipam: rename inconsistent options among files
    c627ea8 dhcp ipam: add more options capable for sending
    4b216e9 dhcp ipam: add fast retry
    2bebd89 dhcp ipam: support customizing dhcp options
    be383cf dhcp ipam: truncate client id to 254 bytes
    6d1f71e dhcp ipam: print error correctly without format string
    24259e7 dhcp ipam: using full config to regular the code
    c16cff9 Allow setting sysctls on a particular interface
    7cb3453 dhcp: remove implemented TODO
    ceb34eb Don't redundantly filepath.Clean the output of filepath.Join
    90c0185 Use crypto/rand.Read, not crypto.Reader.Read
    081ed44 bridge: Add macspoofchk support
    ba48f8a plugins: fix bug where support for CNI version 0.4.0 or 1.0.0 was dropped
    62952ff vendor: bump to libcni v1.0.1
    8ab2336 static ipam: do not parse the CIDR twice
    2052c30 static ipam: improve error msgs when provisioning invalid CIDR
    156e59c bump go to 1.16, other misc fixes
    0818512 vendor: bump all direct dependencies
    9b1666d vendor: bump to libcni v1.0
    0e38a1d docs: Update the CI badge from Travis CI to GitHub Actions
    24b3fbc bridge: Fix typo in error message for promiscuous mode
    a49f908 ip: place veth peer in host namspace directly
    a3cde17 bridge: Add mac field to specify container iface mac
    a786b12 static ipam: decide wrong cidr error msg
    0db5882 static ipam: stop wrapping net.ParseCIDR errors
    5a40818 static ipam: show confusing error msg
    2f9917e utils, hwaddr: Remove unused package
    272f154 ip, link_linux: Remove unused SetHWAddrByIP function
    77233dd plugins: remove flannel
    4b180a9 refactor(win-bridge): netconf
    9215e60 refactor(win-bridge): hcn api processing
    93a5503 refactor(win-bridge): hns api processing
    aa8c8c1 chore(win-bridge): location related
    ec75bb8 chore(win-bridge): text related
    c4d4aa7 Remove Bryan Boreham as maintainer

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-03-21 17:31:29 -04:00
Bruce Ashfield
5b3b2599db cni: add README
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-12-15 12:55:41 -05:00
Bruce Ashfield
24b68f18af cni: don't provide kubernetes-cni by default
The kubernetes recipes can inherit cni_networking and provide their
own PN-cni packages, so we no longer need to provide this by default.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-12-13 15:59:35 -05:00
Bruce Ashfield
0a7ae8bc50 global: convert github SRC_URIs to use https protocol
github is removing git:// access, and fetches will start experiencing
interruptions in service, and eventually will fail completely.

bitbake will also begin to warn on github src_uri's that don't use
https. So we convert the meta-virt instances to use protocol=https
(done using the oe-core contrib conversion script)

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-11-02 09:57:03 -04:00
Bruce Ashfield
36cdef7c5f cni: add SRCREV_FORMAT
recipes that use multiple SCMs in the SRC_URI, must supply
SRCREV_FORMAT or SRCPV triggers an expansion error. While
this isn't fatal during the build, it can cause issues with
setscene (and possibly) other tasks failing, which then
leads to no sstate re-use, etc.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-10-19 23:21:42 -04:00
Bruce Ashfield
d876cfc5bf global: overrides syntax conversion
OEcore/bitbake are moving to use the clearer ":" as an overrides
separator.

This is pass one of updating the meta-virt recipes to use that
syntax.

This has only been minimally build/runtime tested, more changes
will be required for missed overrides, or incorrect conversions

Note: A recent bitbake is required:

    commit 75fad23fc06c008a03414a1fc288a8614c6af9ca
    Author: Richard Purdie <richard.purdie@linuxfoundation.org>
    Date:   Sun Jul 18 12:59:15 2021 +0100

        bitbake: data_smart/parse: Allow ':' characters in variable/function names

        It is becomming increasingly clear we need to find a way to show what
        is/is not an override in our syntax. We need to do this in a way which
        is clear to users, readable and in a way we can transition to.

        The most effective way I've found to this is to use the ":" charater
        to directly replace "_" where an override is being specified. This
        includes "append", "prepend" and "remove" which are effectively special
        override directives.

        This patch simply adds the character to the parser so bitbake accepts
        the value but maps it back to "_" internally so there is no behaviour
        change.

        This change is simple enough it could potentially be backported to older
        version of bitbake meaning layers using the new syntax/markup could
        work with older releases. Even if other no other changes are accepted
        at this time and we don't backport, it does set us on a path where at
        some point in future we could
        require a more explict syntax.

        I've tested this patch by converting oe-core/meta-yocto to the new
        syntax for overrides (9000+ changes) and then seeing that builds
        continue to work with this patch.

        (Bitbake rev: 0dbbb4547cb2570d2ce607e9a53459df3c0ac284)

        Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-08-02 17:17:53 -04:00
Bruce Ashfield
aa2c70a3ad cni: inhibit go.mod build for main cni
The cni plugins already have mod=vendor, but we also need to ensure
that the main CNI build is not using go module based builds.

To avoid inconsistent vendoring messages, we switch all plugins to
no module builds as well.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-06-15 10:33:41 -04:00
Bruce Ashfield
6957b542e3 cni/plugins: update to 0.9.1
Update the cni plugins part of the recipe to the 0.9.1 release:

   c4d4aa7 Remove Bryan Boreham as maintainer
   af26bab host-local: support ip/prefix in env args and CNI args
   f72aa98 [sbr]: Use different tableID for every ipCfg        Check
   tableID not in use for every ipCfg
   40c225e Small typo improves in README.md
   76ef07e Allow multiple routes to be added for the same prefix. Enables ECMP
   d6bf1ea Update to lastest vendor/github.com/vishvananda/netlink
   bdaaa20 tuning: always update MAC in CNI result
   33a2929 vendor: bump to libcni v1.0-rc1
   820fee9 tuning: Add support of altering the allmulticast flag
   f34c600 [sbr]: Use different tableID for every ipCfg        Move default table routes which  match the ipCfg config
   8f32968 Fix nil-pointer check
   028fc2f host-local: support custom IPs allocation through runtime configuration
   7da1c84 pkg/ip: introduce a new type `IP` to support formated <ip>[/<prefix>]
   2eac102 go.mod: github.com/j-keck/arping v1.0.1
   f4d2925 go.mod: github.com/buger/jsonparser v1.1.1
   c3d0153 go.mod: github.com/alexflint/go-filemutex v1.1.0
   75b64e0 go.mod github.com/Microsoft/hcsshim v0.8.16
   bc85637 go.mod: godbus/dbus/v5 v5.0.3, coreos/go-systemd v22.2.0
   d2d89dd go.mod: github.com/mattn/go-shellwords v1.0.11
   59a6259 go.mod: github.com/sirupsen/logrus v1.8.1
   3cc1135 CI: Install linux-modules-extra for VRF module
   5b02c2a Fix broken links to online docs in plugin READMEs
   f275746 gha: update actions/setup-go@v2
   b811967 remove redundant startRange in RangeIter due to overlap check on multi ranges
   178d7c0 fix(win-bridge): panic while calling HNS api
   e09a17f portmap: use slashes in sysctl template to support interface names which separated by dots
   9b09f16 pkg/ipam: use slash as sysctl separator so interface name can have dot
   e31cd2c [macvlan] Stop setting proxy-arp on macvlan interface
   8e540bf tuning: increase test coverage to 1.0.0 and older spec versions
   d2e5b5d portmap: increase test coverage to 1.0.0 and older spec versions
   8f7fe6d flannel: increase test coverage to 1.0.0 and older spec versions
   f33eedb firewall: increase test coverage to 1.0.0 and older spec versions
   da52be3 bandwidth: increase test coverage to 1.0.0 and older spec versions
   02cdaaf host-local: increase test coverage to 1.0.0 and older spec versions
   f534133 static: increase test coverage to 1.0.0 and older spec versions
   932653f dhcp: increase test coverage to 1.0.0 and older spec versions
   dd3f606 dhcp: add -resendmax option to limit lease acquisition time for testcases
   4ddc8ba vlan: increase test coverage to 1.0.0 and older spec versions
   f56545c ptp: increase test coverage to 1.0.0 and older spec versions
   bbf7189 macvlan: increase test coverage to 1.0.0 and older spec versions
   5eae558 loopback: increase test coverage to 1.0.0 and older spec versions
   5096b53 ipvlan: increase test coverage to 1.0.0 and older spec versions
   34cee8c host-device: increase test coverage to 1.0.0 and older spec versions
   c3c286c bridge: increase test coverage to 1.0.0 and older spec versions
   c8f341d bridge: simplify version-based testcase code
   8c25db8 testutils: add test utilities for spec version features
   7d8c767 plugins: update to spec version 1.0.0
   9e2430b vendor: bump CNI to 1.0.0-pre @ 62e54113

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-06-04 08:43:11 -04:00
Bruce Ashfield
df313693f3 cni: add ca-certifcates dependency
Many of the CNI plugins require authenticated connections, as such
they are looking for elements of ca-certificates.

CNI isn't small, so we add this as a general rdepends. If we need to
slim things down in the future, we can split the CNI into specific
implementations and add the dependency to those packages.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-03-15 23:15:42 -04:00
Bruce Ashfield
da32b79488 cni: update to 0.8.0
The following CNI commits are part of this update:

   e32b586 remove build badges from homepage
   296290a Switch from Travis to GH Actions
   a199e6a go fmt
   ada6726 tighten up plugin-finding logic
   eec3755 Add "alias" to conventions
   867451c Fix typo in pkg/types/internal/convert.go
   679ed9d Fix typo in CONVENTIONS.md
   6d8228e maintainers: fix typo
   e781c94 types: remove SupportedVersions
   7555ca3 spec: bump to 1.0.0-pre-release and remove 'version' from Result addresses
   6823eba tests: small cleanup and removal of one useless testcase
   3805b13 types: add 1.0.0
   0050bfa types: implement convert module and make types use it
   90311ea Bump release build Go version to 1.14
   f9b5c9b Add security reporting info
   e5c65a5 Revert formatting of error codes
   65bf688 Travis: bump go versions
   a7cceb9 add go.mod
   93a7425 testhelpers: clean up how we build against old libcni targets
   c78d465 Replace 2019 conference announcement with links to the recordings
   fc1de42 Sync contact methods in README and CONTRIBUTING
   c815aca Update the SPEC, CODE-OF-CONDUCT, CONTRIBUTING, RELEASING with minor formatting changes and linting updates.
   17a6379 Update README.md
   956c943 adding OVN4NFV-K8s-Plugin as 3rd party plugin
   e2a7366 Retry exec commands on text file busy
   76b18ea Typo fixes for infiniband GUID
   44dabed invoke: capture and return stderr if plugin exits unexpectedly
   279bc6c Add DeviceID attribute to RuntimeConfig
   fdcc7b1 test: allow specific package testing with PKGS=<x> ./test.sh
   ca0082f Add Infiniband GUID to well known Capabilities
   38353fa Remove extra ',' chars which makes conflist examples invalid.
   134f603 maintainers: remove Stefan per personal request
   1435c6b Add Michael Cambria as a CNI maintainer
   6b46a03 Update link freenode.org to freenode.net
   075e303 Update roadmap for 1.0 plans
   0b1c649 Change language identifier to jsonc for json with comments
   704c56d Update tests
   f208f19 Remove Result.String
   cc6e8af pkg/utils: utility package should use black-box testing
   025e32f pkg/utils: add utils_test
   6f29b01 intercept netplugin std error
   777584f Add Kube-OVN to CNI list
   e00fa53 appending antrea to the cni list
   7815be7 Add Project Antrea in CNI list
   f2fa4a3 Add table of contents
   b36de6e DOCUMENTATION: Address incomplete instructions in CONTRIBUTING.md
   c35ac21 Adding Cisco ACI to CNI plugin list
   3eb88ac Add Bruce Ma and Piotr Skarmuk as maintainers
   6c6a315 Update README to sunset slack and call out kubecon presentations
   b89eff5 Add a note to README about where to find the binaries
   4eec648 When the CNI version isn't supplied in config, use default.
   eefc069 SPEC: update validation rules for interface name in docs and address some comments
   b5188cf spec: fix some typo in docs
   c94fcd7 Perfect annotation: Correct word spelling mistakes
   7be1ac9 add interface name validation to libcni and skel
   9f4a623 utils: add validation function for interface name
   2a82881 Bump golang
   c0f784d Update cnitool docs
   94399d5 add err handling in plugins/test/noop/
   d8dfb56 validate containerID and networkName ensure they contain only letters and numbers
   e4a11ba libcni: cache file operations require full uniqueness tuple in RuntimeConf
   a83f3cb libcni: also cache IfName, network name, and container ID
   894863c libcni: fix cache file 'result' key name
   f3654f3 skel: remove needless functions and types
   3e79703 modify some well-known errors
   1318d7c libcni: find plugin in exec
   9af40ed     libcni: add config caching
   722a488 docs: add ips and mac to well-known capabilities and fix some typo
   227c438 SPEC: add some well-known error codes
   ba034ef testcases: make testcase use suitable error code
   4b29940 skel: clean up typed Errors in skel
   50192c0 types : add NewError method
   0af0477 readme: add Alibaba Cloud CNI plugin 'Terway' to the list
   b92d83c bump linux to Bionic 18.04 in Travis and Vagrant
   a48337a add missing commas, fix syntax error
   5077b14 Add stringifyArgs and parseArgs functions to utils.go
   80ad241 libcni: add InitCNIConfigWithCacheDir() and deprecate RuntimeConfig.CacheDir
   5dbeae8 clean up : remove useless variable
   a03dc28 clean up : fix staticcheck warnings
   cbca752 Docs: Small typo fixes in main README.md

As well as the following plugin commits:

    fa48f75 ipam/dhcp: Add broadcast flag
    74a6b28 vendor: bump libcni
    8feef71 add flannel to support dual stack ip
    343d233 bandwidth: fix panic in tests
    d41acb8 host-device: Add support for DPDK device (#490)
    075c5a0 [main/vlan] Fix error handling for delegate IPAM plugin
    a8d1f5c dhcp: default dhcp clien timeout is 10s
    354def7 vlan: fix error message text by removing ptp references
    25fc741 dhcp: daemon dhcp client timeout is configurable
    3161bb5 dhcp: timeout value is set in DHCP daemon
    ebce6d0 remove unused function
    691238c deps: go mod tidy coreos/go-iptables
    23a1d90 deps: bump coreos/go-iptables
    e13bab9 tuning: revert values on delete (#540)
    680c6dd go mod tidy
    be19d78 bump to go 1.15
    8d52c42 Add ability to trigger retests via comments
    3ae85c1 pkg/ns: fix test case to tolerate pids going away.
    25704f9 Add github build & test actions
    eb31403 bridge: fix testcase to check addresses we care about
    336ba52 Remove travis.
    b47d178 vendor: bump ginkgo, gover
    108c2ae portmap plugin should flush previous udp connections
    cccf539 Updating plugin README.md files (#549)
    c41c78b update netlink dependencies
    50a3aa6 Xdhcp: fix example configuration
    98c621a VRF: extend supported version to 0.3.1 too.
    b34402a VRF CNI: Add an optional table parameter.
    5fc309a Add more tests for the vrf cni plugin.
    362f5d6 Update github.com/vishvananda/netlink to v1.1.0
    8d0d8a9 Introduce a new VRF CNI meta plugin.
    1a7f1bd Travis: run tests on arm64
    8a6e96b Replace nc with the local echo client.
    3227902 Add an echo client to be used instead of nc.
    59baaa1 Bump up the ubuntu version used in CI to bionic.
    9ce99d3 flannel: allow input ipam parameters as basis for delegate
    08ff3b6 ipvlan: make master config as optional
    1ea19f9 Remove extraneous test file in Windows plugin
    799d3cb Fix race condition in GetCurrentNS
    839d918 lo: CNI_IFNAME is no longer ignored
    c50490e cni: bump to 0.8.0
    01a8de9 Bump Go version to 1.13 and 1.14
    2b6cd54 Add contact info
    0214625 Update firewall README.md CNI-ADMIN
    813f541 firewall: fix some typos in docs
    051452c Update firewall README.md
    877602d portmap DEL noop if no portMappings present
    2bd04cb firewall: fix generate of admin chain comment
    d4775ec Fix handling of delay in acquiring lease with stp turned on
    68a80bc Update README.md
    5cb3a5e portmap: don't use unspecified address as destination
    b9560fd macvlan: set mac address from CNI_ARGS
    79192cb host-device: Bring interfaces down before moving.
    219eb9e ptp, bridge: disable accept_ra on the host-side interface
    02bfece plugins/meta/sbr: Adjusted ipv6 address mask to /128
    5e0fbd8 portmap: Apply the DNAT hairpin to the whole subnet
    a78853f Support device id in host device plugin (#471)
    2d2583e win-bridge: add support for portMappings capability
    30776ff check bridge's port state
    2a48d68 Reset the route flag before moving the rule
    486ef96 [DO NOT REVIEW] vendor upate to remove useless dependencies
    8a0e3fe build error utility package to replace juju/errors
    112288e Unlock OS thread after netns is restored
    c7e2cf7 owners: updates for maintainer changes
    53854dd flannel: remove net conf file after DEL succeed
    a9b4e04 Make host-device to work with virtio net device
    45fd949 ptp: remove some redundant lines
    2ff84a4 pkg/ip: use type cast instead of untrusty error message
    37207f0 pkg/utils: sysctl package should use black-box testing
    d1360b8 loopback: Fix ipv6 address checks

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-02-06 07:56:51 -05:00
Mark Asselstine
de94eb1572 cni: prevent go from downloading stuff in the background
While testing the cni uprev by building in a container with
network=none the following error was found:

  go: github.com/Microsoft/go-winio@v0.4.11: Get
   https://proxy.golang.org/github.com/%21microsoft/go-winio/@v/v0.4.11.mod:
   dial tcp: lookup proxy.golang.org on 128.224.144.130:53:
   dial udp 128.224.144.130:53: connect: network is unreachable

After some digging through the go documentation it was found that the
'-mod=vendor' is required for 'go build' to use shipped vendor modules
when building modules. This can be confirmed by look at the
'build_linux.sh' script which is found in the plugins repo.

By using '-mod=vendor' and also ensuring things are properly placed in
the GOPATH (ie $B) we can avoid having to create many of the links we
had been previously.

We also put all the build artifacts into $B to avoid mixing source and
build.

Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-03-13 21:53:26 -04:00
Mark Asselstine
e65c3761e0 cni: 1.7.0 to 1.7.1 (and plugins 0.8.2 to 0.8.5)
Both uprev's are listed as 'minor' in the upstream release
notes. Neither introduces an uprev in spec. This fixes issues we
observed while testing the forthcoming cri-o uprev.

NOTE: this commit should only be used with the follow-on commit [cni:
prevent go from downloading stuff in the background] otherwise you
will end up with files not owned by you which will prevent the recipe
being properly cleaned.

Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-03-13 21:53:26 -04:00
Stefan Agner
aa509c629e cni: move cni tools to /usr/libexec/cni
Use a standard location to store the cni tools and plugins. This
is more in line how other distributions package cni. Keep a symlink
to /opt/cni/bin for backward compatibility.

Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2019-10-02 14:13:35 -04:00
Chen Qi
b538e06ba9 cni: build more plugins
Also build plugins under ipam. Other distros default to contain
these plugins.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2019-08-12 11:02:31 -04:00
Chen Qi
9267ddff1a cni: fix problem about cross compilation
When setting up k8s, the following error appeared, failing
to setup coredns pod.

  NetworkPlugin cni failed to set up pod "coredns-5f7fc64c95-4nnfq_kube-system" network: fork/exec /opt/cni/bin/loopback: no such file or directory

This is because the binary, /opt/cni/bin/loopback, has wrong interpreter.

So fix do_compile to use ${GO} instead of go to fix this problem.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2019-08-12 11:02:31 -04:00
Chen Qi
4eca42bc3b cni: remove unnecessary GO settings
These settings are either in go.bbclass or duplicate, thus
removing them.

Keep only CGO_ENABLED and GOPATH to easier manipulation while
upgrading cni.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2019-08-12 11:02:31 -04:00
Bruce Ashfield
95b848f219 containers/go/build: don't override global package strip flags
When the go-lang container recipes were first created there were issues
with strip and the resulting binaries. As such, strip was inhibited for
the various packages.

This variable is now set in the default classes, and tests show that
strip works on the binaries (saving up to 2M on disk for some binaries)
with no runtime issues found.

So we drop our explicit set of the inhibit and let the build proceed
by the defaults.

If issues are found, we can re-enable the setting or bbappends can
turn it back on for builds showing issues.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2019-07-22 14:48:07 +00:00
Bruce Ashfield
e6eb8e839b k8s: update CNI to 0.7.x
Updating the CNI and plugins to 0.7.x series.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2019-07-12 14:50:34 +00:00
Bruce Ashfield
3724664413 cni: update to latest plugins, and skip windows bridge build
Updating the cni plugins to match k8s and cri-o. We also filter out
the windows plugins, since they use a different build infrastructure
than the other variants .. and are not currently needed. This can
be revisted in the future as needed.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2018-11-02 21:21:27 -04:00
Bruce Ashfield
1bcc2431a5 cni: update to the latest plugins
Updating the latest plugins.

We have to make some minor build adjustments, but otherwise, this is
a simple update.

We also drop the ptest build, since it is not used and is causing
build errors.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2018-07-04 12:07:09 -04:00
Bruce Ashfield
4c0363bc9b cni: rprovide kubernetes-cni
Many distros make a 'kubernetes-cni' package available. This is no
more than a binary extracted set of 'cni' plugins. We already have
'cni' available in the build system, so we make sure it rprovides
kubernetes-cni to keep conflicts and confusion at a minimum.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2017-10-05 15:50:41 -04:00
Bruce Ashfield
176715435e containers: CNI: introduce container networking interface
Introducing the CNI framework to allow platforms such as
kubernetes + cri-o to use thm for networking configuration.

The networking plugins are installed, but are not configured
by default to create any specific networking interfaces, which
are the responsibility of the image and distribution.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2017-10-02 09:15:58 -04:00