{"record":{"id":"b4553984ca128524","repo":"kubernetes/kops","slug":"parsing-configstore-base-q-w-b45539","errorCode":null,"errorMessage":"parsing configStore.base %q: %w","messagePattern":"parsing configStore\\.base %q: %w","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/model/components/channels/model.go","lineNumber":91,"sourceCode":"\tif err != nil {\n\t\treturn fmt.Errorf(\"marshaling kops-channels pod: %w\", err)\n\t}\n\n\tc.AddTask(&fitasks.ManagedFile{\n\t\tContents:  fi.NewBytesResource(manifest),\n\t\tLifecycle: b.Lifecycle,\n\t\tLocation:  new(channelsManifestPath),\n\t\tName:      new(\"manifests-channels-kops-channels\"),\n\t})\n\treturn nil\n}\n\n// channelList returns the bootstrap channel plus cluster.Spec.Addons. The bootstrap URL is\n// built via vfs path joining so toolbox_enroll's identity comparison stays byte-identical.\nfunc (b *ChannelsBuilder) channelList() ([]string, error) {\n\tconfigBase, err := vfs.Context.BuildVfsPath(b.Cluster.Spec.ConfigStore.Base)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"parsing configStore.base %q: %w\", b.Cluster.Spec.ConfigStore.Base, err)\n\t}\n\tchannels := []string{\n\t\tconfigBase.Join(\"addons\", \"bootstrap-channel.yaml\").Path(),\n\t}\n\tfor i := range b.Cluster.Spec.Addons {\n\t\tchannels = append(channels, b.Cluster.Spec.Addons[i].Manifest)\n\t}\n\treturn channels, nil\n}\n\nfunc (b *ChannelsBuilder) buildPod(channels []string) (*v1.Pod, error) {\n\timage := b.AssetBuilder.RemapImage(\"registry.k8s.io/kops/channels:\" + kopsroot.KopsVersionImageTag())\n\n\tpod := &v1.Pod{\n\t\tTypeMeta: metav1.TypeMeta{\n\t\t\tAPIVersion: \"v1\",\n\t\t\tKind:       \"Pod\",\n\t\t},","sourceCodeStart":73,"sourceCodeEnd":109,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/pkg/model/components/channels/model.go#L73-L109","documentation":"channelList resolves cluster.spec.configStore.base into a vfs path via vfs.Context.BuildVfsPath so the bootstrap channel URL is built consistently. If the base string is not a valid/known VFS path (bad scheme, empty, malformed URL), the parse fails and the whole channels build aborts.","triggerScenarios":"Build (channels addon) runs and vfs.Context.BuildVfsPath is given a configStore.base with an unsupported scheme (e.g. gs:// without GCS support, misspelled s3://, or an empty/relative path).","commonSituations":"Typo in --state / KOPS_STATE_STORE (e.g. 's3:/bucket' with single slash); using a store type the binary wasn't compiled with; empty ConfigStore.Base in a hand-written cluster manifest.","solutions":["Fix the state store URL: full scheme + bucket, e.g. s3://mybucket or gs://mybucket","Verify with `kops get clusters --state <url>` that the base is readable","If using GCS/azure stores, ensure the corresponding cloud provider support is present in your kops build","Export KOPS_STATE_STORE correctly in the environment before running"],"exampleFix":"# before\nconfigStore:\n  base: s3:/mycluster-state\n# after\nconfigStore:\n  base: s3://mycluster-state","handlingStrategy":"validation","validationCode":"if _, err := vfs.Context.BuildVfsPath(cluster.Spec.ConfigStore.Base); err != nil {\n\treturn fmt.Errorf(\"invalid KOPS state store %q: %w\", cluster.Spec.ConfigStore.Base, err)\n}","typeGuard":"func validStateStore(base string) bool {\n\t_, err := vfs.Context.BuildVfsPath(base)\n\treturn base != \"\" && err == nil\n}","tryCatchPattern":"if err := buildChannels(); err != nil {\n\tif strings.Contains(err.Error(), \"parsing configStore.base\") {\n\t\t// check KOPS_STATE_STORE scheme and bucket before retry\n\t}\n\treturn err\n}","preventionTips":["Always use full scheme+bucket for --state (s3://bucket, gs://bucket)","Export KOPS_STATE_STORE once in shell profiles instead of ad-hoc flags","Test state store access with `kops get clusters` before cluster operations"],"tags":["vfs","config-store","state-store"],"backgroundTag":"invalid-storage-path","analyzedSha":"4c8573c808a73d578c5eadc86d410646ea0b0d73","analyzedAt":"2026-09-05T04:13:19.212Z","contentChangedAt":"2026-09-05T04:13:19.212Z","schemaVersion":2},"datasetVersion":"2026-09-12T07:17:12.445Z"}