GoogleContainerTools/skaffold · error
unknown builder for config %+v
Error message
unknown builder for config %+v
What it means
GetBuilder maps the configured build type (docker, ko, bazel, jib, kaniko, custom, etc.) to a builder implementation. This error is returned when the `p.Build` artifact type in the pipeline config matches none of the known builder cases — meaning the default branch of the type switch was reached. It dumps the whole Build config in the message for diagnosis.
Source
Thrown at pkg/skaffold/runner/builder.go:76
return nil, err
}
return builder, nil
case p.Build.GoogleCloudBuild != nil:
log.Entry(context.TODO()).Debug("Using builder: google cloud")
builder := gcb.NewBuilder(bCtx, p.Build.GoogleCloudBuild)
return builder, nil
case p.Build.Cluster != nil:
log.Entry(context.TODO()).Debug("Using builder: cluster")
builder, err := cluster.NewBuilder(bCtx, p.Build.Cluster)
if err != nil {
return nil, err
}
return builder, err
default:
return nil, fmt.Errorf("unknown builder for config %+v", p.Build)
}
}
type pipelineBuilderWithHooks struct {
build.PipelineBuilder
hooksRunner hooks.Runner
}
// PreBuild executes any one-time setup required prior to starting any build on this builder,
// followed by any Build pre-hooks set for the pipeline.
func (b *pipelineBuilderWithHooks) PreBuild(ctx context.Context, out io.Writer) error {
if err := b.PipelineBuilder.PreBuild(ctx, out); err != nil {
return err
}
if err := b.hooksRunner.RunPreHooks(ctx, out); err != nil {
return fmt.Errorf("running builder pre-hooks: %w", err)
}View on GitHub (pinned to a1189de023)
Solutions
- Check the `build:` section of skaffold.yaml and set a supported builder (docker, ko, bazel, jib, kaniko, custom, etc.)
- Upgrade/downgrade Skaffold so it matches the schema version of the config file
- If constructing config in code/tests, ensure the BuildConfig's artifact type field is populated
Example fix
// before (skaffold.yaml)
build:
artifacts:
- image: app
# no builder specified
// after
build:
artifacts:
- image: app
docker:
dockerfile: Dockerfile Defensive patterns
Strategy: validation
Validate before calling
const supported = ['docker','ko','bazel','jib','kaniko','custom','buildpacks']
if (!supported.includes(pipeline.build.artifactType)) {
throw new Error(`unsupported builder: ${pipeline.build.artifactType}`)
} Prevention
- Pin Skaffold version in CI to match the schema version of your skaffold.yaml
- Run `skaffold config` / `skaffold diagnose` to validate configs before builds
- Never leave the build artifact type unset when constructing configs programmatically
When it happens
Trigger: Calling GetBuilder with a pipeline whose BuildConfig holds an artifact type that no builder implementation registered for — e.g. an empty/unset build type, or a config parsed from a newer skaffold.yaml schema field this version doesn't support.
Common situations: Using a skaffold.yaml built for a newer/older Skaffold version with an unsupported builder; manually constructed config structs in tests with the build type left zero-valued.
Related errors
- image %q context %q is not a directory
- getting target platforms: %w
- bucket name is empty
- INSPECT_PROFILE_NOT_FOUND_ERR
- cannot resolve active Kubernetes context - multiple contexts
AI-assisted analysis of GoogleContainerTools/skaffold@a1189de023 (2026-09-05).
Data as JSON: /api/errors/d2851da1fbed7315.
Report an issue: GitHub.