{"record":{"id":"43eafb8a6d702167","repo":"kubernetes/kops","slug":"kops-ipam-controller-not-supported-on-cloud-q","errorCode":null,"errorMessage":"kOps IPAM controller not supported on cloud %q","messagePattern":"kOps IPAM controller not supported on cloud %q","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"nodeup/pkg/model/prefix.go","lineNumber":47,"sourceCode":"}\n\nvar _ fi.NodeupModelBuilder = &PrefixBuilder{}\n\nfunc (b *PrefixBuilder) Build(c *fi.NodeupModelBuilderContext) error {\n\tif !b.IsKopsControllerIPAM() {\n\t\treturn nil\n\t}\n\tswitch b.CloudProvider() {\n\tcase kops.CloudProviderAWS:\n\t\tc.AddTask(&nodetasks.Prefix{\n\t\t\tName: \"prefix\",\n\t\t})\n\tcase kops.CloudProviderGCE:\n\t\t// Prefix is assigned by GCE\n\tcase kops.CloudProviderMetal:\n\t\t// IPv6 must be configured externally (not by nodeup)\n\tdefault:\n\t\treturn fmt.Errorf(\"kOps IPAM controller not supported on cloud %q\", b.CloudProvider())\n\t}\n\treturn nil\n}\n","sourceCodeStart":29,"sourceCodeEnd":51,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/nodeup/pkg/model/prefix.go#L29-L51","documentation":"The kOps IPAM controller (prefix building) only supports clouds where nodeup can manage node IP prefixes: AWS, GCE, and bare metal. Build() is called during nodeup model construction, and if the cluster's CloudProvider is any other value (e.g. OpenStack, Azure, DigitalOcean, Hetzner), it returns this error because kOps IPAM has no implementation for that cloud.","triggerScenarios":"Running nodeup against a cluster whose spec has kOps IPAM enabled (IPv6 prefix delegation) on an unsupported cloud provider — the switch in nodeup/pkg/model/prefix.go:Build falls to the default case because b.CloudProvider() is not AWSspot/GCE/Metal.","commonSituations":"Deploying an IPv6/prefix-delegation cluster spec copied from an AWS or GCE example onto OpenStack, Azure, Hetzner, etc.; upgrading kOps with a config where cloudProvider changed; typos or drift between the cluster spec's cloudProvider and what nodeup was built for.","solutions":["Only enable the kOps IPAM controller on supported clouds (AWS, GCE, metal); use the cloud's native IPAM/CNI features instead on other providers.","Update the cluster spec: remove/disable prefix delegation (kOps IPAM) for the unsupported cloud, e.g. set the networking config appropriately, then run `kops update cluster` and re-bootstrap.","If the cloud is genuinely AWS/GCE/metal, verify nodeup is receiving the correct CloudProvider value (check NodeupConfig / cluster spec cloudProvider field)."],"exampleFix":"// before: kops IPAM enabled on unsupported cloud (e.g. openstack)\nspec:\n  cloudProvider: openstack\n  networking:\n    ipv6: true\n// after: disable prefix/IPAM or move to a supported cloud\nspec:\n  cloudProvider: openstack\n  networking:\n    ipv6: false  # use cloud-native IPAM instead","handlingStrategy":"validation","validationCode":"supported := map[string]bool{\"aws\": true, \"gce\": true, \"metal\": true}\nif !supported[cluster.Spec.CloudProvider] {\n\t// do not enable kOps IPAM / prefix delegation on this cloud\n\tcluster.Spec.Networking.IPv6 = false\n}","typeGuard":"func kopsIPAMSupported(provider string) bool {\n\tswitch provider {\n\tcase \"aws\", \"gce\", \"metal\":\n\t\treturn true\n\t}\n\treturn false\n}","tryCatchPattern":"if err := prefixBuilder.Build(ctx); err != nil {\n\tif strings.Contains(err.Error(), \"IPAM controller not supported on cloud\") {\n\t\tklog.Warningf(\"kOps IPAM unavailable: %v — falling back to cloud-native IPAM\", err)\n\t\treturn nil // skip prefix model\n\t}\n\treturn err\n}","preventionTips":["Enable kOps IPAM/prefix delegation only on AWS, GCE, or bare-metal clusters","Validate cluster specs in CI against a list of IPAM-supported cloud providers","Do not copy IPv6/prefix networking blocks from AWS/GCE example specs onto other clouds","Keep cloudProvider in the cluster spec consistent with the kOps version in use"],"tags":["ipam","ipv6","cloud-provider","nodeup"],"backgroundTag":"unsupported-cloud-provider","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"}