From 498da44aabb3695d410ca63f767c13c71aede836 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 24 Aug 2023 17:46:06 +0200 Subject: [PATCH] remove some remaining pre-go1.17 build-tags commit ab35df454d0666ef1214168938f952cc74c1d659 removed most of the pre-go1.17 build-tags, but for some reason, "go fix" doesn't remove these, so removing the remaining ones manually Signed-off-by: Sebastiaan van Stijn --- daemon/graphdriver/copy/copy.go | 1 - daemon/graphdriver/copy/copy_test.go | 1 - daemon/graphdriver/overlayutils/overlayutils.go | 1 - daemon/graphdriver/overlayutils/randomid.go | 1 - daemon/graphdriver/overlayutils/userxattr.go | 1 - daemon/graphdriver/windows/windows.go | 1 - daemon/initlayer/setup_unix.go | 1 - internal/tools/tools.go | 1 - internal/unshare/unshare_linux.go | 1 - libnetwork/drivers/ipvlan/ipvlan.go | 1 - libnetwork/drivers/ipvlan/ipvlan_endpoint.go | 1 - libnetwork/drivers/ipvlan/ipvlan_joinleave.go | 1 - libnetwork/drivers/ipvlan/ipvlan_network.go | 1 - libnetwork/drivers/ipvlan/ipvlan_setup.go | 1 - libnetwork/drivers/ipvlan/ipvlan_setup_test.go | 1 - libnetwork/drivers/ipvlan/ipvlan_state.go | 1 - libnetwork/drivers/ipvlan/ipvlan_store.go | 1 - libnetwork/drivers/ipvlan/ipvlan_test.go | 1 - libnetwork/drivers/macvlan/macvlan.go | 1 - libnetwork/drivers/macvlan/macvlan_endpoint.go | 1 - libnetwork/drivers/macvlan/macvlan_joinleave.go | 1 - libnetwork/drivers/macvlan/macvlan_network.go | 1 - libnetwork/drivers/macvlan/macvlan_setup.go | 1 - libnetwork/drivers/macvlan/macvlan_setup_test.go | 1 - libnetwork/drivers/macvlan/macvlan_state.go | 1 - libnetwork/drivers/macvlan/macvlan_store.go | 1 - libnetwork/drivers/macvlan/macvlan_test.go | 1 - libnetwork/iptables/conntrack.go | 1 - libnetwork/iptables/firewalld.go | 1 - libnetwork/iptables/firewalld_test.go | 1 - libnetwork/iptables/iptables.go | 1 - libnetwork/iptables/iptables_test.go | 1 - pkg/loopback/attach_loopback.go | 1 - pkg/loopback/loopback.go | 1 - profiles/apparmor/apparmor.go | 1 - profiles/apparmor/template.go | 1 - 36 files changed, 36 deletions(-) diff --git a/daemon/graphdriver/copy/copy.go b/daemon/graphdriver/copy/copy.go index 8136b7a172..1d2ee60b99 100644 --- a/daemon/graphdriver/copy/copy.go +++ b/daemon/graphdriver/copy/copy.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package copy // import "github.com/docker/docker/daemon/graphdriver/copy" diff --git a/daemon/graphdriver/copy/copy_test.go b/daemon/graphdriver/copy/copy_test.go index 34067bc0c3..615e60b2f2 100644 --- a/daemon/graphdriver/copy/copy_test.go +++ b/daemon/graphdriver/copy/copy_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package copy // import "github.com/docker/docker/daemon/graphdriver/copy" diff --git a/daemon/graphdriver/overlayutils/overlayutils.go b/daemon/graphdriver/overlayutils/overlayutils.go index f7cc0de0d1..de69b4bad2 100644 --- a/daemon/graphdriver/overlayutils/overlayutils.go +++ b/daemon/graphdriver/overlayutils/overlayutils.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package overlayutils // import "github.com/docker/docker/daemon/graphdriver/overlayutils" diff --git a/daemon/graphdriver/overlayutils/randomid.go b/daemon/graphdriver/overlayutils/randomid.go index 2c6706b388..ac7d7c8249 100644 --- a/daemon/graphdriver/overlayutils/randomid.go +++ b/daemon/graphdriver/overlayutils/randomid.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package overlayutils // import "github.com/docker/docker/daemon/graphdriver/overlayutils" diff --git a/daemon/graphdriver/overlayutils/userxattr.go b/daemon/graphdriver/overlayutils/userxattr.go index f2139709ff..4de9f8ebd4 100644 --- a/daemon/graphdriver/overlayutils/userxattr.go +++ b/daemon/graphdriver/overlayutils/userxattr.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux // Forked from https://github.com/containerd/containerd/blob/9ade247b38b5a685244e1391c86ff41ab109556e/snapshots/overlay/check.go /* diff --git a/daemon/graphdriver/windows/windows.go b/daemon/graphdriver/windows/windows.go index fa9a23548d..b5fa3630e6 100644 --- a/daemon/graphdriver/windows/windows.go +++ b/daemon/graphdriver/windows/windows.go @@ -1,5 +1,4 @@ //go:build windows -// +build windows package windows // import "github.com/docker/docker/daemon/graphdriver/windows" diff --git a/daemon/initlayer/setup_unix.go b/daemon/initlayer/setup_unix.go index 51621e4eb7..0f0f2f69f5 100644 --- a/daemon/initlayer/setup_unix.go +++ b/daemon/initlayer/setup_unix.go @@ -1,5 +1,4 @@ //go:build linux || freebsd -// +build linux freebsd package initlayer // import "github.com/docker/docker/daemon/initlayer" diff --git a/internal/tools/tools.go b/internal/tools/tools.go index 042824dfb6..9fc13732ef 100644 --- a/internal/tools/tools.go +++ b/internal/tools/tools.go @@ -1,5 +1,4 @@ //go:build tools -// +build tools // Package tools tracks dependencies on binaries not referenced in this codebase. // https://github.com/golang/go/wiki/Modules#how-can-i-track-tool-dependencies-for-a-module diff --git a/internal/unshare/unshare_linux.go b/internal/unshare/unshare_linux.go index 14bbec4871..0b210e8193 100644 --- a/internal/unshare/unshare_linux.go +++ b/internal/unshare/unshare_linux.go @@ -1,5 +1,4 @@ //go:build go1.10 -// +build go1.10 package unshare // import "github.com/docker/docker/internal/unshare" diff --git a/libnetwork/drivers/ipvlan/ipvlan.go b/libnetwork/drivers/ipvlan/ipvlan.go index a55bb61056..416c20c258 100644 --- a/libnetwork/drivers/ipvlan/ipvlan.go +++ b/libnetwork/drivers/ipvlan/ipvlan.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_endpoint.go b/libnetwork/drivers/ipvlan/ipvlan_endpoint.go index ff730add84..fa772ab49c 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_endpoint.go +++ b/libnetwork/drivers/ipvlan/ipvlan_endpoint.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_joinleave.go b/libnetwork/drivers/ipvlan/ipvlan_joinleave.go index 635fc277c5..ac7fe93dfd 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_joinleave.go +++ b/libnetwork/drivers/ipvlan/ipvlan_joinleave.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_network.go b/libnetwork/drivers/ipvlan/ipvlan_network.go index 84befa4f11..11e7868608 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_network.go +++ b/libnetwork/drivers/ipvlan/ipvlan_network.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_setup.go b/libnetwork/drivers/ipvlan/ipvlan_setup.go index 97142472a3..08ec727fb7 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_setup.go +++ b/libnetwork/drivers/ipvlan/ipvlan_setup.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_setup_test.go b/libnetwork/drivers/ipvlan/ipvlan_setup_test.go index ef50f46109..5429596a2d 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_setup_test.go +++ b/libnetwork/drivers/ipvlan/ipvlan_setup_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_state.go b/libnetwork/drivers/ipvlan/ipvlan_state.go index 55243897b7..8816f64243 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_state.go +++ b/libnetwork/drivers/ipvlan/ipvlan_state.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_store.go b/libnetwork/drivers/ipvlan/ipvlan_store.go index f6ceffc456..5b2dfe5a9c 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_store.go +++ b/libnetwork/drivers/ipvlan/ipvlan_store.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/ipvlan/ipvlan_test.go b/libnetwork/drivers/ipvlan/ipvlan_test.go index d27688e27d..77ae3fb173 100644 --- a/libnetwork/drivers/ipvlan/ipvlan_test.go +++ b/libnetwork/drivers/ipvlan/ipvlan_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package ipvlan diff --git a/libnetwork/drivers/macvlan/macvlan.go b/libnetwork/drivers/macvlan/macvlan.go index 8c586ad27a..e518394ebf 100644 --- a/libnetwork/drivers/macvlan/macvlan.go +++ b/libnetwork/drivers/macvlan/macvlan.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_endpoint.go b/libnetwork/drivers/macvlan/macvlan_endpoint.go index f8334ba4ba..ec9ceda3fe 100644 --- a/libnetwork/drivers/macvlan/macvlan_endpoint.go +++ b/libnetwork/drivers/macvlan/macvlan_endpoint.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_joinleave.go b/libnetwork/drivers/macvlan/macvlan_joinleave.go index e1b2ac5265..2531d65a9c 100644 --- a/libnetwork/drivers/macvlan/macvlan_joinleave.go +++ b/libnetwork/drivers/macvlan/macvlan_joinleave.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_network.go b/libnetwork/drivers/macvlan/macvlan_network.go index db6141cc51..ce00f1033b 100644 --- a/libnetwork/drivers/macvlan/macvlan_network.go +++ b/libnetwork/drivers/macvlan/macvlan_network.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_setup.go b/libnetwork/drivers/macvlan/macvlan_setup.go index ee267553a8..4b8f22c7c0 100644 --- a/libnetwork/drivers/macvlan/macvlan_setup.go +++ b/libnetwork/drivers/macvlan/macvlan_setup.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_setup_test.go b/libnetwork/drivers/macvlan/macvlan_setup_test.go index f2053c1679..6663d636f3 100644 --- a/libnetwork/drivers/macvlan/macvlan_setup_test.go +++ b/libnetwork/drivers/macvlan/macvlan_setup_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_state.go b/libnetwork/drivers/macvlan/macvlan_state.go index 2135b7bd7a..ef5aad1017 100644 --- a/libnetwork/drivers/macvlan/macvlan_state.go +++ b/libnetwork/drivers/macvlan/macvlan_state.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_store.go b/libnetwork/drivers/macvlan/macvlan_store.go index 2ea3d1a14f..f4b0f47ac7 100644 --- a/libnetwork/drivers/macvlan/macvlan_store.go +++ b/libnetwork/drivers/macvlan/macvlan_store.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/drivers/macvlan/macvlan_test.go b/libnetwork/drivers/macvlan/macvlan_test.go index 05ffffeed8..5bc2c0e686 100644 --- a/libnetwork/drivers/macvlan/macvlan_test.go +++ b/libnetwork/drivers/macvlan/macvlan_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package macvlan diff --git a/libnetwork/iptables/conntrack.go b/libnetwork/iptables/conntrack.go index 2af8ec907f..d4cfa02d28 100644 --- a/libnetwork/iptables/conntrack.go +++ b/libnetwork/iptables/conntrack.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package iptables diff --git a/libnetwork/iptables/firewalld.go b/libnetwork/iptables/firewalld.go index c659c94dc6..fd792d43f7 100644 --- a/libnetwork/iptables/firewalld.go +++ b/libnetwork/iptables/firewalld.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package iptables diff --git a/libnetwork/iptables/firewalld_test.go b/libnetwork/iptables/firewalld_test.go index b72444370c..1ec9233940 100644 --- a/libnetwork/iptables/firewalld_test.go +++ b/libnetwork/iptables/firewalld_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package iptables diff --git a/libnetwork/iptables/iptables.go b/libnetwork/iptables/iptables.go index f13a91f530..0c845fc36d 100644 --- a/libnetwork/iptables/iptables.go +++ b/libnetwork/iptables/iptables.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package iptables diff --git a/libnetwork/iptables/iptables_test.go b/libnetwork/iptables/iptables_test.go index bdfb1721c1..fd7f574e21 100644 --- a/libnetwork/iptables/iptables_test.go +++ b/libnetwork/iptables/iptables_test.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package iptables diff --git a/pkg/loopback/attach_loopback.go b/pkg/loopback/attach_loopback.go index 035fe5edf6..5a789a0d07 100644 --- a/pkg/loopback/attach_loopback.go +++ b/pkg/loopback/attach_loopback.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package loopback // import "github.com/docker/docker/pkg/loopback" diff --git a/pkg/loopback/loopback.go b/pkg/loopback/loopback.go index 7e7c3b96f3..0a855b6c80 100644 --- a/pkg/loopback/loopback.go +++ b/pkg/loopback/loopback.go @@ -1,5 +1,4 @@ //go:build linux && cgo -// +build linux,cgo package loopback // import "github.com/docker/docker/pkg/loopback" diff --git a/profiles/apparmor/apparmor.go b/profiles/apparmor/apparmor.go index d0f2361605..f7ecb46a8f 100644 --- a/profiles/apparmor/apparmor.go +++ b/profiles/apparmor/apparmor.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package apparmor // import "github.com/docker/docker/profiles/apparmor" diff --git a/profiles/apparmor/template.go b/profiles/apparmor/template.go index 5dcf35bf45..7db753de13 100644 --- a/profiles/apparmor/template.go +++ b/profiles/apparmor/template.go @@ -1,5 +1,4 @@ //go:build linux -// +build linux package apparmor // import "github.com/docker/docker/profiles/apparmor"