diff --git a/.golangci.yml b/.golangci.yml index 069183482b..593d231533 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -132,6 +132,7 @@ linters-settings: replace-allow-list: - gopkg.in/yaml.v3 - github.com/vmware-tanzu/sonobuoy + - golang.org/x/sys retract-allow-no-explanation: false exclude-forbidden: true @@ -170,6 +171,9 @@ linters: - nakedret # too annoying - depguard - tagalign # too annoying + - testifylint # too annoying + - inamedparam # too annoying + - protogetter # too annoying # abandoned linters for which golangci shows the warning that the repo is archived by the owner - golint diff --git a/Makefile b/Makefile index 00edd86264..7c943b9aac 100644 --- a/Makefile +++ b/Makefile @@ -15,10 +15,10 @@ NAME = Talos CLOUD_IMAGES_EXTRA_ARGS ?= "" ARTIFACTS := _out -TOOLS ?= ghcr.io/siderolabs/tools:v1.6.0-alpha.0-5-g9c09b00 -PKGS ?= v1.6.0-alpha.0-23-g2e892fd +TOOLS ?= ghcr.io/siderolabs/tools:v1.6.0-alpha.0-12-gff7fe96 +PKGS ?= v1.6.0-alpha.0-29-g252a59f PKG_KERNEL ?= ghcr.io/siderolabs/kernel:$(PKGS) -EXTRAS ?= v1.6.0-alpha.0-2-g6d48418 +EXTRAS ?= v1.6.0-alpha.0-5-ge8e801b # renovate: datasource=github-tags depName=golang/go GO_VERSION ?= 1.21 # renovate: datasource=go depName=golang.org/x/tools @@ -26,13 +26,13 @@ GOIMPORTS_VERSION ?= v0.14.0 # renovate: datasource=go depName=mvdan.cc/gofumpt GOFUMPT_VERSION ?= v0.5.0 # renovate: datasource=go depName=github.com/golangci/golangci-lint -GOLANGCILINT_VERSION ?= v1.54.2 +GOLANGCILINT_VERSION ?= v1.55.2 # renovate: datasource=go depName=golang.org/x/tools STRINGER_VERSION ?= v0.14.0 # renovate: datasource=go depName=github.com/alvaroloes/enumer ENUMER_VERSION ?= v1.1.2 # renovate: datasource=go depName=k8s.io/code-generator -DEEPCOPY_GEN_VERSION ?= v0.28.2 +DEEPCOPY_GEN_VERSION ?= v0.28.3 # renovate: datasource=go depName=github.com/planetscale/vtprotobuf VTPROTOBUF_VERSION ?= v0.5.0 # renovate: datasource=go depName=github.com/siderolabs/deep-copy @@ -61,9 +61,9 @@ KUBESTR_VERSION ?= v0.4.41 # renovate: datasource=github-releases depName=helm/helm HELM_VERSION ?= v3.13.1 # renovate: datasource=github-releases depName=kubernetes-sigs/cluster-api -CLUSTERCTL_VERSION ?= 1.5.2 +CLUSTERCTL_VERSION ?= 1.5.3 # renovate: datasource=github-releases depName=cilium/cilium-cli -CILIUM_CLI_VERSION ?= v0.15.11 +CILIUM_CLI_VERSION ?= v0.15.13 KUBECTL_URL ?= https://dl.k8s.io/release/$(KUBECTL_VERSION)/bin/$(OPERATING_SYSTEM)/amd64/kubectl KUBESTR_URL ?= https://github.com/kastenhq/kubestr/releases/download/$(KUBESTR_VERSION)/kubestr_$(subst v,,$(KUBESTR_VERSION))_Linux_amd64.tar.gz HELM_URL ?= https://get.helm.sh/helm-$(HELM_VERSION)-linux-amd64.tar.gz diff --git a/cmd/installer/cmd/installer/root.go b/cmd/installer/cmd/installer/root.go index a542c5e242..81fa02136d 100644 --- a/cmd/installer/cmd/installer/root.go +++ b/cmd/installer/cmd/installer/root.go @@ -52,6 +52,7 @@ var options = &install.Options{} var bootloader bool +//nolint:goconst func init() { rootCmd.PersistentFlags().StringVar(&options.ConfigSource, "config", "", "The value of "+constants.KernelParamConfig) rootCmd.PersistentFlags().StringVar(&options.Disk, "disk", "", "The path to the disk to install to") diff --git a/cmd/talosctl/cmd/mgmt/gen/ca.go b/cmd/talosctl/cmd/mgmt/gen/ca.go index eab993452c..99ff6c265f 100644 --- a/cmd/talosctl/cmd/mgmt/gen/ca.go +++ b/cmd/talosctl/cmd/mgmt/gen/ca.go @@ -41,9 +41,9 @@ var genCACmd = &cobra.Command{ return fmt.Errorf("error generating CA: %w", err) } - caCertFile := genCACmdFlags.organization + ".crt" + caCertFile := genCACmdFlags.organization + crtExt caHashFile := genCACmdFlags.organization + ".sha256" - caKeyFile := genCACmdFlags.organization + ".key" + caKeyFile := genCACmdFlags.organization + keyExt if err := validateFilesExists([]string{caCertFile, caHashFile, caKeyFile}); err != nil { return err diff --git a/cmd/talosctl/cmd/mgmt/gen/config.go b/cmd/talosctl/cmd/mgmt/gen/config.go index de833d1615..a8aa8c234b 100644 --- a/cmd/talosctl/cmd/mgmt/gen/config.go +++ b/cmd/talosctl/cmd/mgmt/gen/config.go @@ -37,6 +37,8 @@ const ( talosconfigOutputType = "talosconfig" stdoutOutput = "-" + + yamlExt = ".yaml" ) var allOutputTypes = []string{ @@ -365,8 +367,8 @@ func outputPaths() (configOutputPaths, error) { return configOutputPaths{}, err } - controlPlane := filepath.Join(cwd, machine.TypeControlPlane.String()+".yaml") - worker := filepath.Join(cwd, machine.TypeWorker.String()+".yaml") + controlPlane := filepath.Join(cwd, machine.TypeControlPlane.String()+yamlExt) + worker := filepath.Join(cwd, machine.TypeWorker.String()+yamlExt) talosconfig := filepath.Join(cwd, "talosconfig") return configOutputPaths{controlPlane: controlPlane, worker: worker, talosconfig: talosconfig}, nil @@ -385,8 +387,8 @@ func outputPaths() (configOutputPaths, error) { } // treat --output as a directory - controlPlane := filepath.Join(genConfigCmdFlags.output, machine.TypeControlPlane.String()+".yaml") - worker := filepath.Join(genConfigCmdFlags.output, machine.TypeWorker.String()+".yaml") + controlPlane := filepath.Join(genConfigCmdFlags.output, machine.TypeControlPlane.String()+yamlExt) + worker := filepath.Join(genConfigCmdFlags.output, machine.TypeWorker.String()+yamlExt) talosconfig := filepath.Join(genConfigCmdFlags.output, "talosconfig") return configOutputPaths{controlPlane: controlPlane, worker: worker, talosconfig: talosconfig}, nil diff --git a/cmd/talosctl/cmd/mgmt/gen/crt.go b/cmd/talosctl/cmd/mgmt/gen/crt.go index 100dbe7bac..9ddd0c0086 100644 --- a/cmd/talosctl/cmd/mgmt/gen/crt.go +++ b/cmd/talosctl/cmd/mgmt/gen/crt.go @@ -31,7 +31,7 @@ var genCrtCmd = &cobra.Command{ Long: ``, Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { - caBytes, err := os.ReadFile(genCrtCmdFlags.ca + ".crt") + caBytes, err := os.ReadFile(genCrtCmdFlags.ca + crtExt) if err != nil { return fmt.Errorf("error reading CA cert: %s", err) } @@ -46,7 +46,7 @@ var genCrtCmd = &cobra.Command{ return fmt.Errorf("error parsing cert: %s", err) } - keyBytes, err := os.ReadFile(genCrtCmdFlags.ca + ".key") + keyBytes, err := os.ReadFile(genCrtCmdFlags.ca + keyExt) if err != nil { return fmt.Errorf("error reading key file: %s", err) } @@ -85,7 +85,7 @@ var genCrtCmd = &cobra.Command{ return fmt.Errorf("error signing certificate: %s", err) } - certFile := genCrtCmdFlags.name + ".crt" + certFile := genCrtCmdFlags.name + crtExt if err = validateFileExists(certFile); err != nil { return err diff --git a/cmd/talosctl/cmd/mgmt/gen/gen.go b/cmd/talosctl/cmd/mgmt/gen/gen.go index b94f24dfba..d1735f816d 100644 --- a/cmd/talosctl/cmd/mgmt/gen/gen.go +++ b/cmd/talosctl/cmd/mgmt/gen/gen.go @@ -12,6 +12,11 @@ import ( "github.com/spf13/cobra" ) +const ( + crtExt = ".crt" + keyExt = ".key" +) + var genCmdFlags struct { force bool } diff --git a/cmd/talosctl/cmd/mgmt/gen/key.go b/cmd/talosctl/cmd/mgmt/gen/key.go index 7c70714690..58d46e7d0d 100644 --- a/cmd/talosctl/cmd/mgmt/gen/key.go +++ b/cmd/talosctl/cmd/mgmt/gen/key.go @@ -30,7 +30,7 @@ var genKeyCmd = &cobra.Command{ return fmt.Errorf("error generating key: %w", err) } - keyFile := genKeyCmdFlags.name + ".key" + keyFile := genKeyCmdFlags.name + keyExt if err = validateFileExists(keyFile); err != nil { return err diff --git a/cmd/talosctl/cmd/mgmt/gen/keypair.go b/cmd/talosctl/cmd/mgmt/gen/keypair.go index 857d93377d..7ac8c8e488 100644 --- a/cmd/talosctl/cmd/mgmt/gen/keypair.go +++ b/cmd/talosctl/cmd/mgmt/gen/keypair.go @@ -44,8 +44,8 @@ var genKeypairCmd = &cobra.Command{ return fmt.Errorf("error generating CA: %s", err) } - certFile := genKeypairCmdFlags.organization + ".crt" - keyFile := genKeypairCmdFlags.organization + ".key" + certFile := genKeypairCmdFlags.organization + crtExt + keyFile := genKeypairCmdFlags.organization + keyExt if err = validateFilesExists([]string{certFile, keyFile}); err != nil { return err diff --git a/cmd/talosctl/cmd/talos/disks.go b/cmd/talosctl/cmd/talos/disks.go index 45d3ba3d02..298f0d4b3f 100644 --- a/cmd/talosctl/cmd/talos/disks.go +++ b/cmd/talosctl/cmd/talos/disks.go @@ -86,7 +86,7 @@ func printDisks(ctx context.Context, c *client.Client) error { for j, disk := range message.Disks { if i == 0 && j == 0 { if node != "" { - fmt.Fprintln(w, "NODE\t"+labels) + fmt.Fprintln(w, "NODE\t"+labels) //nolint:goconst } else { fmt.Fprintln(w, labels) } diff --git a/cmd/talosctl/cmd/talos/diskusage.go b/cmd/talosctl/cmd/talos/diskusage.go index fbb8a35f1c..1a36564f7a 100644 --- a/cmd/talosctl/cmd/talos/diskusage.go +++ b/cmd/talosctl/cmd/talos/diskusage.go @@ -8,6 +8,7 @@ import ( "context" "fmt" "os" + "strconv" "text/tabwriter" "github.com/dustin/go-humanize" @@ -73,7 +74,7 @@ var duCmd = &cobra.Command{ return humanize.Bytes(uint64(s)) } - return fmt.Sprintf("%d", s) + return strconv.FormatInt(s, 10) } defer w.Flush() //nolint:errcheck diff --git a/cmd/talosctl/cmd/talos/etcd.go b/cmd/talosctl/cmd/talos/etcd.go index 6672b102eb..0edb6fef48 100644 --- a/cmd/talosctl/cmd/talos/etcd.go +++ b/cmd/talosctl/cmd/talos/etcd.go @@ -62,7 +62,7 @@ func displayAlarms(messages []alarmMessage) error { if i == 0 && j == 0 { if node != "" { header = "NODE\t" + header - pattern = "%s\t" + pattern + pattern = "%s\t" + pattern //nolint:goconst } fmt.Fprintln(w, header) diff --git a/cmd/talosctl/cmd/talos/list.go b/cmd/talosctl/cmd/talos/list.go index 7f587632cb..b50a202ced 100644 --- a/cmd/talosctl/cmd/talos/list.go +++ b/cmd/talosctl/cmd/talos/list.go @@ -8,6 +8,7 @@ import ( "context" "fmt" "os" + "strconv" "strings" "text/tabwriter" "time" @@ -127,7 +128,7 @@ var lsCmd = &cobra.Command{ display += " -> " + info.Link } - size := fmt.Sprintf("%d", info.Size) + size := strconv.FormatInt(info.Size, 10) if humanizeFlag { size = humanize.Bytes(uint64(info.Size)) diff --git a/cmd/talosctl/cmd/talos/pcap.go b/cmd/talosctl/cmd/talos/pcap.go index 832ccef5dc..700de9cbb6 100644 --- a/cmd/talosctl/cmd/talos/pcap.go +++ b/cmd/talosctl/cmd/talos/pcap.go @@ -95,7 +95,7 @@ e.g. by excluding packets with the port 50000. } if pcapCmdFlags.output == "" { - return dumpPackets(r) + return dumpPackets(ctx, r) } var out io.Writer @@ -120,15 +120,20 @@ e.g. by excluding packets with the port 50000. }, } -func dumpPackets(r io.Reader) error { +func dumpPackets(ctx context.Context, r io.Reader) error { src, err := pcapgo.NewReader(r) if err != nil { + if errors.Is(err, io.EOF) { + // nothing in the capture at all + return nil + } + return fmt.Errorf("error opening pcap reader: %w", err) } packetSource := gopacket.NewPacketSource(src, src.LinkType()) - for packet := range packetSource.Packets() { + for packet := range packetSource.PacketsCtx(ctx) { fmt.Println(packet) } @@ -178,7 +183,7 @@ func parseBPFInstructions(in string) ([]*machine.BPFInstruction, error) { func init() { pcapCmd.Flags().StringVarP(&pcapCmdFlags.iface, "interface", "i", "eth0", "interface name to capture packets on") pcapCmd.Flags().BoolVar(&pcapCmdFlags.promisc, "promiscuous", false, "put interface into promiscuous mode") - pcapCmd.Flags().IntVarP(&pcapCmdFlags.snaplen, "snaplen", "s", 65536, "maximum packet size to capture") + pcapCmd.Flags().IntVarP(&pcapCmdFlags.snaplen, "snaplen", "s", 4096, "maximum packet size to capture") pcapCmd.Flags().StringVarP(&pcapCmdFlags.output, "output", "o", "", "if not set, decode packets to stdout; if set write raw pcap data to a file, use '-' for stdout") pcapCmd.Flags().StringVar(&pcapCmdFlags.bpfFilter, "bpf-filter", "", "bpf filter to apply, tcpdump -dd format") pcapCmd.Flags().DurationVar(&pcapCmdFlags.duration, "duration", 0, "duration of the capture") diff --git a/go.mod b/go.mod index c256cc2a2e..acaa583eb1 100644 --- a/go.mod +++ b/go.mod @@ -1,11 +1,14 @@ module github.com/siderolabs/talos -go 1.21.3 +go 1.21.4 replace ( // Use nested module. github.com/siderolabs/talos/pkg/machinery => ./pkg/machinery + // github.com/cilium/ebpf@v0.11.0/internal/unix/types_linux.go:41:36: undefined: linux.BPF_F_KPROBE_MULTI_RETURN + golang.org/x/sys => golang.org/x/sys v0.13.0 + // forked go-yaml that introduces RawYAML interface, which can be used to populate YAML fields using bytes // which are then encoded as a valid YAML blocks with proper indentiation gopkg.in/yaml.v3 => github.com/unix4ever/yaml v0.0.0-20220527175918-f17b0f05cf2c @@ -26,7 +29,7 @@ require ( require ( cloud.google.com/go/compute/metadata v0.2.3 github.com/BurntSushi/toml v1.3.2 - github.com/aws/aws-sdk-go-v2/config v1.22.0 + github.com/aws/aws-sdk-go-v2/config v1.22.2 github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.14.2 github.com/aws/smithy-go v1.16.0 github.com/beevik/ntp v1.3.0 @@ -34,7 +37,7 @@ require ( github.com/blang/semver/v4 v4.0.0 github.com/cenkalti/backoff/v4 v4.2.1 github.com/containerd/cgroups/v3 v3.0.2 - github.com/containerd/containerd v1.7.7 + github.com/containerd/containerd v1.7.8 github.com/containerd/typeurl/v2 v2.1.1 github.com/containernetworking/cni v1.1.2 github.com/containernetworking/plugins v1.3.0 @@ -46,7 +49,7 @@ require ( github.com/dustin/go-humanize v1.0.1 github.com/ecks/uefi v0.0.0-20221116212947-caef65d070eb github.com/emicklei/dot v1.6.0 - github.com/fatih/color v1.15.0 + github.com/fatih/color v1.16.0 github.com/foxboron/go-uefi v0.0.0-20230808201820-18b9ba9cd4c3 github.com/freddierice/go-losetup/v2 v2.0.1 github.com/fsnotify/fsnotify v1.7.0 @@ -116,7 +119,7 @@ require ( github.com/siderolabs/net v0.4.0 github.com/siderolabs/siderolink v0.3.1 github.com/siderolabs/talos/pkg/machinery v1.6.0-alpha.1 - github.com/spf13/cobra v1.7.0 + github.com/spf13/cobra v1.8.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.4 github.com/u-root/u-root v0.11.0 @@ -132,11 +135,11 @@ require ( go.uber.org/zap v1.26.0 go4.org/netipx v0.0.0-20230824141953-6213f710f925 golang.org/x/net v0.17.0 - golang.org/x/sync v0.4.0 - golang.org/x/sys v0.13.0 - golang.org/x/term v0.13.0 - golang.org/x/text v0.13.0 - golang.org/x/time v0.3.0 + golang.org/x/sync v0.5.0 + golang.org/x/sys v0.14.0 + golang.org/x/term v0.14.0 + golang.org/x/text v0.14.0 + golang.org/x/time v0.4.0 golang.zx2c4.com/wireguard/wgctrl v0.0.0-20230429144221-925a1e7659e6 google.golang.org/grpc v1.59.0 google.golang.org/protobuf v1.31.0 @@ -164,7 +167,7 @@ require ( github.com/aws/aws-sdk-go-v2/credentials v1.15.1 // indirect github.com/aws/aws-sdk-go-v2/internal/configsources v1.2.1 // indirect github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.5.1 // indirect - github.com/aws/aws-sdk-go-v2/internal/ini v1.5.0 // indirect + github.com/aws/aws-sdk-go-v2/internal/ini v1.5.1 // indirect github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.10.1 // indirect github.com/aws/aws-sdk-go-v2/service/sso v1.17.0 // indirect github.com/aws/aws-sdk-go-v2/service/ssooidc v1.19.0 // indirect @@ -185,7 +188,7 @@ require ( github.com/containerd/ttrpc v1.2.2 // indirect github.com/coreos/go-semver v0.3.1 // indirect github.com/coreos/go-systemd/v22 v22.5.0 // indirect - github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect + github.com/cpuguy83/go-md2man/v2 v2.0.3 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/docker/cli v24.0.0+incompatible // indirect github.com/docker/distribution v2.8.3+incompatible // indirect diff --git a/go.sum b/go.sum index 9f0449da3d..4995500e52 100644 --- a/go.sum +++ b/go.sum @@ -74,8 +74,8 @@ github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPd github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/aws/aws-sdk-go-v2 v1.22.1 h1:sjnni/AuoTXxHitsIdT0FwmqUuNUuHtufcVDErVFT9U= github.com/aws/aws-sdk-go-v2 v1.22.1/go.mod h1:Kd0OJtkW3Q0M0lUWGszapWjEvrXDzRW+D21JNsroB+c= -github.com/aws/aws-sdk-go-v2/config v1.22.0 h1:9Mm99OalzZRz0ab5fpodMoHBApHS6pqRNp3M9NmzvDg= -github.com/aws/aws-sdk-go-v2/config v1.22.0/go.mod h1:2eWgw5lps8fKI7LZVTrRTYP6HE6k/uEFUuTSHfXwqP0= +github.com/aws/aws-sdk-go-v2/config v1.22.2 h1:fuDAlqkXcf7taDK4i1ejaAzDKajnlvHRQldqz649DeY= +github.com/aws/aws-sdk-go-v2/config v1.22.2/go.mod h1:cBBFBM39pRUzw4dCLuRYkTDeIcscOtfFQNbQcgWnbL4= github.com/aws/aws-sdk-go-v2/credentials v1.15.1 h1:hmf6lAm9hk7uLCfapZn/jL05lm6Uwdbn1B0fgjyuf4M= github.com/aws/aws-sdk-go-v2/credentials v1.15.1/go.mod h1:QTcHga3ZbQOneJuxmGBOCxiClxmp+TlvmjFexAnJ790= github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.14.2 h1:gIeH4+o1MN/caGBWjoGQTUTIu94xD6fI5B2+TcwBf70= @@ -84,8 +84,8 @@ github.com/aws/aws-sdk-go-v2/internal/configsources v1.2.1 h1:fi1ga6WysOyYb5PAf3 github.com/aws/aws-sdk-go-v2/internal/configsources v1.2.1/go.mod h1:V5CY8wNurvPUibTi9mwqUqpiFZ5LnioKWIFUDtIzdI8= github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.5.1 h1:ZpaV/j48RlPc4AmOZuPv22pJliXjXq8/reL63YzyFnw= github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.5.1/go.mod h1:R8aXraabD2e3qv1csxM14/X9WF4wFMIY0kH4YEtYD5M= -github.com/aws/aws-sdk-go-v2/internal/ini v1.5.0 h1:DqOQvIfmGkXZUVJnl9VRk0AnxyS59tCtX9k1Pyss4Ak= -github.com/aws/aws-sdk-go-v2/internal/ini v1.5.0/go.mod h1:VV/Kbw9Mg1GWJOT9WK+oTL3cWZiXtapnNvDSRqTZLsg= +github.com/aws/aws-sdk-go-v2/internal/ini v1.5.1 h1:6zMMQmHFW0F+2bnK2Y66lleMjrmvPU6sbhKVqNcqCMg= +github.com/aws/aws-sdk-go-v2/internal/ini v1.5.1/go.mod h1:VV/Kbw9Mg1GWJOT9WK+oTL3cWZiXtapnNvDSRqTZLsg= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.10.1 h1:2OXw3ppu1XsB6rqKEMV4tnecTjIY3PRV2U6IP6KPJQo= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.10.1/go.mod h1:FZB4AdakIqW/yERVdGJA6Z9jraax1beXfhBBnK2wwR8= github.com/aws/aws-sdk-go-v2/service/sso v1.17.0 h1:I/Oh3IxGPfHXiGnwM54TD6hNr/8TlUrBXAtTyGhR+zw= @@ -141,8 +141,8 @@ github.com/containerd/cgroups v1.1.0/go.mod h1:6ppBcbh/NOOUU+dMKrykgaBnK9lCIBxHq github.com/containerd/cgroups/v3 v3.0.2 h1:f5WFqIVSgo5IZmtTT3qVBo6TzI1ON6sycSBKkymb9L0= github.com/containerd/cgroups/v3 v3.0.2/go.mod h1:JUgITrzdFqp42uI2ryGA+ge0ap/nxzYgkGmIcetmErE= github.com/containerd/console v1.0.3/go.mod h1:7LqA/THxQ86k76b8c/EMSiaJ3h1eZkMkXar0TQ1gf3U= -github.com/containerd/containerd v1.7.7 h1:QOC2K4A42RQpcrZyptP6z9EJZnlHfHJUfZrAAHe15q4= -github.com/containerd/containerd v1.7.7/go.mod h1:3c4XZv6VeT9qgf9GMTxNTMFxGJrGpI2vz1yk4ye+YY8= +github.com/containerd/containerd v1.7.8 h1:RkwgOW3AVUT3H/dyT0W03Dc8AzlpMG65lX48KftOFSM= +github.com/containerd/containerd v1.7.8/go.mod h1:L/Hn9qylJtUFT7cPeM0Sr3fATj+WjHwRQ0lyrYk3OPY= github.com/containerd/continuity v0.4.2 h1:v3y/4Yz5jwnvqPKJJ+7Wf93fyWoCB3F5EclWG023MDM= github.com/containerd/continuity v0.4.2/go.mod h1:F6PTNCKepoxEaXLQp3wDAjygEnImnZ/7o4JzpodfroQ= github.com/containerd/fifo v1.1.0 h1:4I2mbh5stb1u6ycIABlBw9zgtlK8viPI9QkQNRQEEmY= @@ -171,8 +171,9 @@ github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSV github.com/cosi-project/runtime v0.3.16 h1:mAtiBeRCC7V0QenEpm5Way2vTS/Mef6x0nt9l8BU3vc= github.com/cosi-project/runtime v0.3.16/go.mod h1:nQ7sThCDAK8nJh/wRxSHOuyR3GouldcYUQfveorfX9E= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= -github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.3 h1:qMCsGGgs+MAzDFyp9LpAe1Lqy/fY/qCovCm0qnXZOBM= +github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= @@ -220,8 +221,8 @@ github.com/evanphx/json-patch v5.7.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLi github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d h1:105gxyaGwCFad8crR9dcMQWvV9Hvulu6hwUh4tWPJnM= github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d/go.mod h1:ZZMPRZwes7CROmyNKgQzC3XPs6L/G2EJLHddWejkmf4= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= -github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw= +github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM= +github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE= github.com/foxboron/go-uefi v0.0.0-20230808201820-18b9ba9cd4c3 h1:SJMQFT74bCrP+kQ24oWhmuyPFHDTavrd3JMIe//2NhU= github.com/foxboron/go-uefi v0.0.0-20230808201820-18b9ba9cd4c3/go.mod h1:VdozURTQHi5Rs54l+4Szi3yIJQDMfXXYrRLAjKKowWI= github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k= @@ -681,8 +682,8 @@ github.com/spf13/afero v1.9.3 h1:41FoI0fD7OR7mGcKE/aOiLkGreyf8ifIOQmJANWogMk= github.com/spf13/afero v1.9.3/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= github.com/spf13/cast v1.5.0 h1:rj3WzYc11XZaIZMPKmwP96zkFEnnAmV8s6XbB2aY32w= github.com/spf13/cast v1.5.0/go.mod h1:SpXXQ5YoyJw6s3/6cMTQuxvgRl3PCJiyaX9p6b155UU= -github.com/spf13/cobra v1.7.0 h1:hyqWnYt1ZQShIddO5kBpj3vu05/++x6tJ6dg8EC572I= -github.com/spf13/cobra v1.7.0/go.mod h1:uLxZILRyS/50WlhOIKD7W6V5bgeIt+4sICxh6uRMrb0= +github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= +github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk= github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= @@ -917,79 +918,8 @@ golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= -golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190606203320-7fc4e5ec1444/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200217220822-9197077df867/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200728102440-3e129f6d46b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210616045830-e2b7044e8c71/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210906170528-6f6e22806c34/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211116061358-0a5406a5449c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220622161953-175b2fd9d664/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220906165534-d0df966e6959/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.9.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.10.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= @@ -1000,8 +930,8 @@ golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= golang.org/x/term v0.9.0/go.mod h1:M6DEAAIenWoTxdKrOltXcmDY3rSplQUkrvaDU5FcQyo= -golang.org/x/term v0.13.0 h1:bb+I9cTfFazGW51MZqBVmZy7+JEJMouUHTUSKVQLBek= -golang.org/x/term v0.13.0/go.mod h1:LTmsnFJwVN6bCy1rVCoS+qHT1HhALEFxKncY3WNNh4U= +golang.org/x/term v0.14.0 h1:LGK9IlZ8T9jvdy6cTdfKUCltatMFOehAQo9SRC46UQ8= +golang.org/x/term v0.14.0/go.mod h1:TySc+nGkYR6qt8km8wUhuFRTVSMIX3XPR58y2lC8vww= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1015,13 +945,13 @@ golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= golang.org/x/text v0.10.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= -golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= -golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= -golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.4.0 h1:Z81tqI5ddIoXDPvVQ7/7CC9TnLM7ubaFG2qXYd5BbYY= +golang.org/x/time v0.4.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= diff --git a/go.work b/go.work index bc7c391ec8..f58ab246aa 100644 --- a/go.work +++ b/go.work @@ -1,4 +1,4 @@ -go 1.21.3 +go 1.21.4 use ( . diff --git a/hack/cloud-image-uploader/go.mod b/hack/cloud-image-uploader/go.mod index b4a60f3e0d..e09f2d2c87 100644 --- a/hack/cloud-image-uploader/go.mod +++ b/hack/cloud-image-uploader/go.mod @@ -1,28 +1,28 @@ module github.com/siderolabs/cloud-image-uploader -go 1.21.3 +go 1.21.4 require ( github.com/Azure/azure-sdk-for-go v68.0.0+incompatible - github.com/Azure/azure-sdk-for-go/sdk/azcore v1.8.0 + github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.0 github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.4.0 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5 v5.2.0 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage v1.4.0 github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.2.0 github.com/Azure/go-autorest/autorest v0.11.29 github.com/Azure/go-autorest/autorest/azure/auth v0.5.12 - github.com/aws/aws-sdk-go v1.47.2 + github.com/aws/aws-sdk-go v1.47.5 github.com/blang/semver/v4 v4.0.0 github.com/google/uuid v1.4.0 github.com/siderolabs/gen v0.4.7 github.com/siderolabs/go-retry v0.3.3 github.com/spf13/pflag v1.0.5 github.com/ulikunitz/xz v0.5.11 - golang.org/x/sync v0.4.0 + golang.org/x/sync v0.5.0 ) require ( - github.com/Azure/azure-sdk-for-go/sdk/internal v1.3.0 // indirect + github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.0 // indirect github.com/Azure/go-autorest v14.2.0+incompatible // indirect github.com/Azure/go-autorest/autorest/adal v0.9.23 // indirect github.com/Azure/go-autorest/autorest/azure/cli v0.4.6 // indirect diff --git a/hack/cloud-image-uploader/go.sum b/hack/cloud-image-uploader/go.sum index 7325d248c0..769646098e 100644 --- a/hack/cloud-image-uploader/go.sum +++ b/hack/cloud-image-uploader/go.sum @@ -1,11 +1,11 @@ github.com/Azure/azure-sdk-for-go v68.0.0+incompatible h1:fcYLmCpyNYRnvJbPerq7U0hS+6+I79yEDJBqVNcqUzU= github.com/Azure/azure-sdk-for-go v68.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc= -github.com/Azure/azure-sdk-for-go/sdk/azcore v1.8.0 h1:9kDVnTz3vbfweTqAUmk/a/pH5pWFCHtvRpHYC0G/dcA= -github.com/Azure/azure-sdk-for-go/sdk/azcore v1.8.0/go.mod h1:3Ug6Qzto9anB6mGlEdgYMDF5zHQ+wwhEaYR4s17PHMw= +github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.0 h1:fb8kj/Dh4CSwgsOzHeZY4Xh68cFVbzXx+ONXGMY//4w= +github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.0/go.mod h1:uReU2sSxZExRPBAg3qKzmAucSi51+SP1OhohieR821Q= github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.4.0 h1:BMAjVKJM0U/CYF27gA0ZMmXGkOcvfFtD0oHVZ1TIPRI= github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.4.0/go.mod h1:1fXstnBMas5kzG+S3q8UoJcmyU6nUeunJcMDHcRYHhs= -github.com/Azure/azure-sdk-for-go/sdk/internal v1.3.0 h1:sXr+ck84g/ZlZUOZiNELInmMgOsuGwdjjVkEIde0OtY= -github.com/Azure/azure-sdk-for-go/sdk/internal v1.3.0/go.mod h1:okt5dMMTOFjX/aovMlrjvvXoPMBVSPzk9185BT0+eZM= +github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.0 h1:d81/ng9rET2YqdVkVwkb6EXeRrLJIwyGnJcAlAWKwhs= +github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.0/go.mod h1:s4kgfzA0covAXNicZHDMN58jExvcng2mC/DepXiF1EI= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5 v5.2.0 h1:PutmjTnIYf/rM5OlNGpAXcL+b2Fa2ErD5IsOjXEHYyg= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5 v5.2.0/go.mod h1:c3iwOnL5Xq5K9ZOvxBrfZYD4pBDNTGK5b7ptkHN6SDs= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/internal v1.1.2 h1:mLY+pNLjCUeKhgnAJWAKhEUQM+RJQo2H1fuGSw1Ky1E= @@ -45,8 +45,8 @@ github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUM github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/AzureAD/microsoft-authentication-library-for-go v1.1.1 h1:WpB/QDNLpMw72xHJc34BNNykqSOeEJDAWkhf0u12/Jk= github.com/AzureAD/microsoft-authentication-library-for-go v1.1.1/go.mod h1:wP83P5OoQ5p6ip3ScPr0BAq0BvuPAvacpEuSzyouqAI= -github.com/aws/aws-sdk-go v1.47.2 h1:KEdO2PbjfEBmHvnEwbYEpr65ZIkmwK5aB85Gj19ASuA= -github.com/aws/aws-sdk-go v1.47.2/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= +github.com/aws/aws-sdk-go v1.47.5 h1:U2JlfPmrUoz5p+2X/XwKxmaJFo2oV+LbJqx8jyEvyAY= +github.com/aws/aws-sdk-go v1.47.5/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM= github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -111,8 +111,8 @@ golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= diff --git a/hack/docgen/go.mod b/hack/docgen/go.mod index ffa9b609ac..598e56a335 100644 --- a/hack/docgen/go.mod +++ b/hack/docgen/go.mod @@ -1,6 +1,6 @@ module github.com/siderolabs/talos-hack-docgen -go 1.21.3 +go 1.21.4 // forked go-yaml that introduces RawYAML interface, which can be used to populate YAML fields using bytes // which are then encoded as a valid YAML blocks with proper indentiation diff --git a/hack/gotagsrewrite/go.mod b/hack/gotagsrewrite/go.mod index cd1890a4bc..69266127b3 100644 --- a/hack/gotagsrewrite/go.mod +++ b/hack/gotagsrewrite/go.mod @@ -4,7 +4,7 @@ go 1.20 require ( github.com/fatih/structtag v1.2.0 - github.com/spf13/cobra v1.7.0 + github.com/spf13/cobra v1.8.0 github.com/stretchr/testify v1.8.4 ) diff --git a/hack/gotagsrewrite/go.sum b/hack/gotagsrewrite/go.sum index 5a0f2bcbe6..19a9cbaae8 100644 --- a/hack/gotagsrewrite/go.sum +++ b/hack/gotagsrewrite/go.sum @@ -1,4 +1,4 @@ -github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -19,8 +19,8 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/spf13/cobra v1.7.0 h1:hyqWnYt1ZQShIddO5kBpj3vu05/++x6tJ6dg8EC572I= -github.com/spf13/cobra v1.7.0/go.mod h1:uLxZILRyS/50WlhOIKD7W6V5bgeIt+4sICxh6uRMrb0= +github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= +github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= diff --git a/hack/release.toml b/hack/release.toml index a5011a6a3c..6203f92d38 100644 --- a/hack/release.toml +++ b/hack/release.toml @@ -26,14 +26,15 @@ This also ensures that the linux-firmware is not tied to a specific Talos versio [notes.updates] title = "Component Updates" description = """\ -Linux: 6.1.58 -containerd: 1.7.7 +Linux: 6.1.61 +containerd: 1.7.8 CoreDNS: 1.11.1 Kubernetes: 1.29.0-alpha.3 Flannel: 0.22.3 etcd: 3.5.10 +runc: 1.1.10 -Talos is built with Go 1.21.3. +Talos is built with Go 1.21.4. """ [notes.talosctl] diff --git a/hack/structprotogen/go.mod b/hack/structprotogen/go.mod index 723654c118..7da4b0226c 100644 --- a/hack/structprotogen/go.mod +++ b/hack/structprotogen/go.mod @@ -1,10 +1,10 @@ module github.com/siderolabs/structprotogen -go 1.21.3 +go 1.21.4 require ( github.com/fatih/structtag v1.2.0 - github.com/spf13/cobra v1.7.0 + github.com/spf13/cobra v1.8.0 golang.org/x/tools v0.14.0 gopkg.in/typ.v4 v4.3.0 ) diff --git a/hack/structprotogen/go.sum b/hack/structprotogen/go.sum index ed44728908..07fb1853f3 100644 --- a/hack/structprotogen/go.sum +++ b/hack/structprotogen/go.sum @@ -1,11 +1,11 @@ -github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/fatih/structtag v1.2.0 h1:/OdNE99OxoI/PqaW/SuSK9uxxT3f/tcSZgon/ssNSx4= github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4/aAZl94= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/spf13/cobra v1.7.0 h1:hyqWnYt1ZQShIddO5kBpj3vu05/++x6tJ6dg8EC572I= -github.com/spf13/cobra v1.7.0/go.mod h1:uLxZILRyS/50WlhOIKD7W6V5bgeIt+4sICxh6uRMrb0= +github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= +github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= golang.org/x/mod v0.13.0 h1:I/DsJXRlw/8l/0c24sM9yb0T4z9liZTduXvdAWYiysY= diff --git a/internal/app/machined/internal/server/v1alpha1/v1alpha1_server.go b/internal/app/machined/internal/server/v1alpha1/v1alpha1_server.go index 4f0cf7525b..31f12d1937 100644 --- a/internal/app/machined/internal/server/v1alpha1/v1alpha1_server.go +++ b/internal/app/machined/internal/server/v1alpha1/v1alpha1_server.go @@ -18,6 +18,7 @@ import ( "net" "os" "path/filepath" + "slices" "strings" "syscall" "time" @@ -2155,6 +2156,22 @@ func (s *Server) GenerateClientConfiguration(ctx context.Context, in *machine.Ge return reply, nil } +type packetStreamWriter struct { + stream machine.MachineService_PacketCaptureServer +} + +func (w *packetStreamWriter) Write(data []byte) (int, error) { + // copy the data as the stream may not send it immediately + data = slices.Clone(data) + + err := w.stream.Send(&common.Data{Bytes: data}) + if err != nil { + return 0, err + } + + return len(data), nil +} + // PacketCapture performs packet capture and streams the pcap file. // //nolint:gocyclo @@ -2179,10 +2196,8 @@ func (s *Server) PacketCapture(in *machine.PacketCaptureRequest, srv machine.Mac return status.Errorf(codes.InvalidArgument, "unsupported link type %s", linkInfo.TypedSpec().Type) } - pr, pw := io.Pipe() - if in.SnapLen == 0 { - in.SnapLen = 65536 + in.SnapLen = afpacket.DefaultFrameSize } filter := make([]bpf.RawInstruction, 0, len(in.BpfFilter)) @@ -2199,7 +2214,7 @@ func (s *Server) PacketCapture(in *machine.PacketCaptureRequest, srv machine.Mac handle, err := afpacket.NewTPacket( afpacket.OptInterface(in.Interface), afpacket.OptFrameSize(int(in.SnapLen)), - afpacket.OptBlockSize(int(in.SnapLen)*128), + afpacket.OptPollTimeout(100*time.Millisecond), ) if err != nil { return fmt.Errorf("error creating afpacket handle: %w", err) @@ -2219,40 +2234,17 @@ func (s *Server) PacketCapture(in *machine.PacketCaptureRequest, srv machine.Mac return fmt.Errorf("error setting promiscuous mode %v: %w", in.Promiscuous, err) } - // start packet capture in a goroutine which writes to a pipe back - go capturePackets(pw, handle, in.SnapLen, linkType) - - // main goroutine reads the .pcap from the file and delivers it to the client in chunks - defer pr.Close() //nolint:errcheck - - ctx, cancel := context.WithCancel(srv.Context()) - defer cancel() - - chunker := stream.NewChunker(ctx, pr) - chunkCh := chunker.Read() - - for data := range chunkCh { - if err = srv.SendMsg(&common.Data{Bytes: data}); err != nil { - cancel() - - pr.CloseWithError(err) - } - } - - return nil + return capturePackets(srv.Context(), &packetStreamWriter{srv}, handle, in.SnapLen, linkType) } -//nolint:gocyclo -func capturePackets(pw *io.PipeWriter, handle *afpacket.TPacket, snapLen uint32, linkType pcap.LinkType) { - defer pw.Close() //nolint:errcheck +//nolint:gocyclo,cyclop +func capturePackets(ctx context.Context, w io.Writer, handle *afpacket.TPacket, snapLen uint32, linkType pcap.LinkType) error { defer handle.Close() - pcapw := pcap.NewWriter(pw) + pcapw := pcap.NewWriter(w) if err := pcapw.WriteFileHeader(snapLen, linkType); err != nil { - pw.CloseWithError(err) - - return + return err } defer func() { @@ -2272,12 +2264,16 @@ func capturePackets(pw *io.PipeWriter, handle *afpacket.TPacket, snapLen uint32, }() for { + select { + case <-ctx.Done(): + return ctx.Err() + default: + } + data, captureData, err := handle.ZeroCopyReadPacketData() if err == nil { if err = pcapw.WritePacket(captureData, data); err != nil { - pw.CloseWithError(err) - - return + return err } continue @@ -2288,19 +2284,17 @@ func capturePackets(pw *io.PipeWriter, handle *afpacket.TPacket, snapLen uint32, continue } - // Immediately retry for EAGAIN - if errors.Is(err, syscall.EAGAIN) { + // Immediately retry for EAGAIN and poll timeout + if errors.Is(err, syscall.EAGAIN) || errors.Is(err, afpacket.ErrTimeout) { continue } // Immediately break for known unrecoverable errors if errors.Is(err, io.EOF) || errors.Is(err, io.ErrUnexpectedEOF) || errors.Is(err, io.ErrNoProgress) || errors.Is(err, io.ErrClosedPipe) || errors.Is(err, io.ErrShortBuffer) || - errors.Is(err, syscall.EBADF) || + errors.Is(err, syscall.EBADF) || errors.Is(err, afpacket.ErrPoll) || strings.Contains(err.Error(), "use of closed file") { - pw.CloseWithError(err) - - return + return err } time.Sleep(5 * time.Millisecond) // short sleep before retrying some errors diff --git a/internal/app/machined/pkg/controllers/kubeaccess/serviceaccount/crd_controller.go b/internal/app/machined/pkg/controllers/kubeaccess/serviceaccount/crd_controller.go index 07f94ff701..cec2b34f51 100644 --- a/internal/app/machined/pkg/controllers/kubeaccess/serviceaccount/crd_controller.go +++ b/internal/app/machined/pkg/controllers/kubeaccess/serviceaccount/crd_controller.go @@ -336,7 +336,7 @@ func (t *CRDController) syncHandler(ctx context.Context, key string) error { desiredRoles, found, err := unstructured.NestedStringSlice(talosSA.UnstructuredContent(), "spec", "roles") if err != nil || !found { - msg := fmt.Sprint(messageRolesNotFound) + msg := messageRolesNotFound updateErr := t.updateTalosSAStatus(ctx, talosSA, msg) if updateErr != nil { diff --git a/internal/app/machined/pkg/runtime/v1alpha1/platform/openstack/metadata.go b/internal/app/machined/pkg/runtime/v1alpha1/platform/openstack/metadata.go index a5783d9ec0..093c007021 100644 --- a/internal/app/machined/pkg/runtime/v1alpha1/platform/openstack/metadata.go +++ b/internal/app/machined/pkg/runtime/v1alpha1/platform/openstack/metadata.go @@ -30,16 +30,18 @@ const ( configNetworkDataPath = "openstack/latest/network_data.json" configUserDataPath = "openstack/latest/user_data" + endpoint = "http://169.254.169.254/" + // OpenstackExternalIPEndpoint is the local Openstack endpoint for the external IP. - OpenstackExternalIPEndpoint = "http://169.254.169.254/latest/meta-data/public-ipv4" + OpenstackExternalIPEndpoint = endpoint + "latest/meta-data/public-ipv4" // OpenstackInstanceTypeEndpoint is the local Openstack endpoint for the instance-type. - OpenstackInstanceTypeEndpoint = "http://169.254.169.254/latest/meta-data/instance-type" + OpenstackInstanceTypeEndpoint = endpoint + "latest/meta-data/instance-type" // OpenstackMetaDataEndpoint is the local Openstack endpoint for the meta config. - OpenstackMetaDataEndpoint = "http://169.254.169.254/" + configMetadataPath + OpenstackMetaDataEndpoint = endpoint + configMetadataPath // OpenstackNetworkDataEndpoint is the local Openstack endpoint for the network config. - OpenstackNetworkDataEndpoint = "http://169.254.169.254/" + configNetworkDataPath + OpenstackNetworkDataEndpoint = endpoint + configNetworkDataPath // OpenstackUserDataEndpoint is the local Openstack endpoint for the config. - OpenstackUserDataEndpoint = "http://169.254.169.254/" + configUserDataPath + OpenstackUserDataEndpoint = endpoint + configUserDataPath ) // NetworkConfig holds NetworkData config. diff --git a/internal/app/machined/pkg/system/runner/containerd/containerd_test.go b/internal/app/machined/pkg/system/runner/containerd/containerd_test.go index e6b6d24c30..1d1aa3dd60 100644 --- a/internal/app/machined/pkg/system/runner/containerd/containerd_test.go +++ b/internal/app/machined/pkg/system/runner/containerd/containerd_test.go @@ -2,6 +2,7 @@ // License, v. 2.0. If a copy of the MPL was not distributed with this // file, You can obtain one at http://mozilla.org/MPL/2.0/. +//nolint:goconst package containerd_test import ( diff --git a/internal/integration/cli/pcap.go b/internal/integration/cli/pcap.go index 10d526f47d..d6ecddfa57 100644 --- a/internal/integration/cli/pcap.go +++ b/internal/integration/cli/pcap.go @@ -23,7 +23,7 @@ func (suite *PcapSuite) SuiteName() string { // TestLoopback verifies that there are some packets on loopback interface. func (suite *PcapSuite) TestLoopback() { - suite.RunCLI([]string{"pcap", "--interface", "lo", "--nodes", suite.RandomDiscoveredNodeInternalIP(machine.TypeControlPlane), "--duration", "1s"}) // default checks for stdout not empty + suite.RunCLI([]string{"pcap", "--interface", "lo", "--nodes", suite.RandomDiscoveredNodeInternalIP(machine.TypeControlPlane), "--duration", "2s"}) // default checks for stdout not empty } func init() { diff --git a/internal/pkg/dashboard/components/header.go b/internal/pkg/dashboard/components/header.go index f4cc857be5..392ae71c14 100644 --- a/internal/pkg/dashboard/components/header.go +++ b/internal/pkg/dashboard/components/header.go @@ -7,6 +7,7 @@ package components import ( "fmt" "math" + "strconv" "time" "github.com/dustin/go-humanize" @@ -146,7 +147,7 @@ func (widget *Header) updateNodeAPIData(node string, data *apidata.Node) { if data.CPUsInfo != nil { numCPUs := len(data.CPUsInfo.GetCpuInfo()) - nodeData.numCPUs = fmt.Sprintf("%d", numCPUs) + nodeData.numCPUs = strconv.Itoa(numCPUs) if numCPUs > 0 { nodeData.cpuFreq = widget.humanizeCPUFrequency(data.CPUsInfo.GetCpuInfo()[0].GetCpuMhz()) @@ -154,7 +155,7 @@ func (widget *Header) updateNodeAPIData(node string, data *apidata.Node) { } if data.Processes != nil { - nodeData.numProcesses = fmt.Sprintf("%d", len(data.Processes.GetProcesses())) + nodeData.numProcesses = strconv.Itoa(len(data.Processes.GetProcesses())) } if data.Memory != nil { diff --git a/internal/pkg/encryption/encryption.go b/internal/pkg/encryption/encryption.go index a3b510863c..29d09834a5 100644 --- a/internal/pkg/encryption/encryption.go +++ b/internal/pkg/encryption/encryption.go @@ -229,7 +229,7 @@ func (h *Handler) syncKeys(ctx context.Context, path string, handlers []keys.Han visited := map[string]bool{} for _, handler := range handlers { - slot := fmt.Sprintf("%d", handler.Slot()) + slot := strconv.Itoa(handler.Slot()) visited[slot] = true // no need to update the key which we already detected as unchanged if k.Slot == handler.Slot() { diff --git a/pkg/archiver/walker_test.go b/pkg/archiver/walker_test.go index caf49860a2..ae7b1310e1 100644 --- a/pkg/archiver/walker_test.go +++ b/pkg/archiver/walker_test.go @@ -6,9 +6,9 @@ package archiver_test import ( "context" - "fmt" "os" "path/filepath" + "strconv" "testing" "github.com/stretchr/testify/suite" @@ -98,7 +98,7 @@ func (suite *WalkerSuite) TestIterationMaxRecurseDepth() { }, } { test := test - suite.Run(fmt.Sprint(test.maxDepth), func() { + suite.Run(strconv.Itoa(test.maxDepth), func() { suite.T().Parallel() ch, err := archiver.Walker(context.Background(), suite.tmpDir, archiver.WithMaxRecurseDepth(test.maxDepth)) diff --git a/pkg/chunker/stream/stream.go b/pkg/chunker/stream/stream.go index 3fbd62b603..76c5b83daa 100644 --- a/pkg/chunker/stream/stream.go +++ b/pkg/chunker/stream/stream.go @@ -6,6 +6,7 @@ package stream import ( "context" + "errors" "fmt" "io" @@ -80,7 +81,7 @@ func (c *Stream) Read() <-chan []byte { n, err := c.source.Read(buf) if err != nil { - if err != io.EOF { + if !(errors.Is(err, io.EOF) || errors.Is(err, io.ErrClosedPipe)) { fmt.Printf("read error: %s\n", err.Error()) } diff --git a/pkg/cluster/sonobuoy/sonobuoy.go b/pkg/cluster/sonobuoy/sonobuoy.go index f200a7b811..7a2b9e24b6 100644 --- a/pkg/cluster/sonobuoy/sonobuoy.go +++ b/pkg/cluster/sonobuoy/sonobuoy.go @@ -13,6 +13,7 @@ import ( "io" "os" "path/filepath" + "strconv" "strings" "time" @@ -193,7 +194,7 @@ func Run(ctx context.Context, cluster cluster.K8sProvider, options *Options) err runConfig.PluginEnvOverrides = map[string]map[string]string{ "e2e": { "E2E_FOCUS": strings.Join(options.RunTests, "|"), - "E2E_PARALLEL": fmt.Sprintf("%v", options.Parallel), + "E2E_PARALLEL": strconv.FormatBool(options.Parallel), "E2E_EXTRA_ARGS": "--ginkgo.v", }, } diff --git a/pkg/imager/ova/ova.go b/pkg/imager/ova/ova.go index 33d611bd7f..4291ddc620 100644 --- a/pkg/imager/ova/ova.go +++ b/pkg/imager/ova/ova.go @@ -8,7 +8,7 @@ package ova import ( "bytes" "crypto/sha256" - "fmt" + "encoding/hex" "io" "os" "path/filepath" @@ -214,7 +214,7 @@ func sha256sum(input io.Reader) (string, error) { sum := hash.Sum(nil) - return fmt.Sprintf("%x", sum), nil + return hex.EncodeToString(sum), nil } func renderMF(vmdkSHA25Sum, ovfSHA25Sum string) (string, error) { diff --git a/pkg/machinery/config/types/v1alpha1/v1alpha1_validation.go b/pkg/machinery/config/types/v1alpha1/v1alpha1_validation.go index 6c45b099ac..dd5e53a5cc 100644 --- a/pkg/machinery/config/types/v1alpha1/v1alpha1_validation.go +++ b/pkg/machinery/config/types/v1alpha1/v1alpha1_validation.go @@ -794,7 +794,7 @@ func CheckDeviceAddressing(d *Device, bondedInterfaces map[string]string) ([]str // CheckDeviceRoutes ensures that the specified routes are valid. // -//nolint:gocyclo +//nolint:gocyclo,goconst func CheckDeviceRoutes(d *Device, _ map[string]string) ([]string, error) { var result *multierror.Error diff --git a/pkg/machinery/constants/constants.go b/pkg/machinery/constants/constants.go index fa2b5eb2a7..876109e582 100644 --- a/pkg/machinery/constants/constants.go +++ b/pkg/machinery/constants/constants.go @@ -2,6 +2,9 @@ // License, v. 2.0. If a copy of the MPL was not distributed with this // file, You can obtain one at http://mozilla.org/MPL/2.0/. +// Package constants defines constants used throughout Talos. +// +//nolint:goconst package constants import ( @@ -13,7 +16,7 @@ import ( const ( // DefaultKernelVersion is the default Linux kernel version. - DefaultKernelVersion = "6.1.58-talos" + DefaultKernelVersion = "6.1.61-talos" // KernelModulesPath is the default path to the kernel modules without the kernel version. KernelModulesPath = "/lib/modules" @@ -443,7 +446,7 @@ const ( TrustdUserID = 51 // DefaultContainerdVersion is the default container runtime version. - DefaultContainerdVersion = "1.7.7" + DefaultContainerdVersion = "1.7.8" // SystemContainerdNamespace is the Containerd namespace for Talos services. SystemContainerdNamespace = "system" @@ -829,7 +832,7 @@ const ( DBusClientSocketPath = "/run/dbus/system_bus_socket" // GoVersion is the version of Go compiler this release was built with. - GoVersion = "go1.21.3 X:loopvar" + GoVersion = "go1.21.4 X:loopvar" // KubernetesTalosAPIServiceName is the name of the Kubernetes service to access Talos API. KubernetesTalosAPIServiceName = "talos" diff --git a/pkg/machinery/gendata/data/extras b/pkg/machinery/gendata/data/extras index 7169425f4f..7ddd8946b0 100644 --- a/pkg/machinery/gendata/data/extras +++ b/pkg/machinery/gendata/data/extras @@ -1 +1 @@ -v1.6.0-alpha.0-2-g6d48418 \ No newline at end of file +v1.6.0-alpha.0-5-ge8e801b \ No newline at end of file diff --git a/pkg/machinery/gendata/data/pkgs b/pkg/machinery/gendata/data/pkgs index ce7a4051b6..b342370cef 100644 --- a/pkg/machinery/gendata/data/pkgs +++ b/pkg/machinery/gendata/data/pkgs @@ -1 +1 @@ -v1.6.0-alpha.0-23-g2e892fd \ No newline at end of file +v1.6.0-alpha.0-29-g252a59f \ No newline at end of file diff --git a/pkg/machinery/go.mod b/pkg/machinery/go.mod index a04d0b5e2a..3e2847c7c6 100644 --- a/pkg/machinery/go.mod +++ b/pkg/machinery/go.mod @@ -1,6 +1,6 @@ module github.com/siderolabs/talos/pkg/machinery -go 1.21.3 +go 1.21.4 // forked go-yaml that introduces RawYAML interface, which can be used to populate YAML fields using bytes // which are then encoded as a valid YAML blocks with proper indentiation diff --git a/website/content/v1.6/reference/cli.md b/website/content/v1.6/reference/cli.md index 544d94ccd8..d28867ec7f 100644 --- a/website/content/v1.6/reference/cli.md +++ b/website/content/v1.6/reference/cli.md @@ -2453,7 +2453,7 @@ talosctl pcap [flags] -i, --interface string interface name to capture packets on (default "eth0") -o, --output string if not set, decode packets to stdout; if set write raw pcap data to a file, use '-' for stdout --promiscuous put interface into promiscuous mode - -s, --snaplen int maximum packet size to capture (default 65536) + -s, --snaplen int maximum packet size to capture (default 4096) ``` ### Options inherited from parent commands