Skaffold "unknown apiVersion" parsing skaffold config in CI
Skaffold parses skaffold.yaml against a fixed set of known schema versions. If the file declares an apiVersion the installed binary does not recognize, it stops before doing any build or deploy. The CI Skaffold version and the file schema are out of step.
What this error means
A build or deploy step fails immediately with "parsing skaffold config: unknown apiVersion" and the version string from the top of skaffold.yaml.
parsing skaffold config: unknown apiVersion "skaffold/v4beta11". Please check
if the config is valid and the apiVersion is supported by this version of skaffoldCommon causes
The file schema is newer than the CI binary
skaffold.yaml declares apiVersion: skaffold/v4beta11 but the runner has an older Skaffold that only knows up to an earlier schema, so it cannot parse it.
The CI binary is newer than the pinned schema
A very old apiVersion may be dropped in a newer Skaffold; the binary no longer accepts it without an upgrade of the file.
How to fix it
Pin the Skaffold version in CI to match the schema
- Read the
apiVersionat the top of skaffold.yaml. - Install a Skaffold release that supports that schema on the runner.
- Run
skaffold versionin the job to confirm the installed binary.
- name: Install Skaffold
run: |
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/v2.13.2/skaffold-linux-amd64
sudo install skaffold /usr/local/bin/
skaffold versionUpgrade the config schema with skaffold fix
Have Skaffold rewrite skaffold.yaml to the newest schema the binary supports, then commit the result.
skaffold fix --overwriteHow to prevent it
- Pin an exact Skaffold version in CI instead of "latest".
- Keep skaffold.yaml apiVersion aligned with the pinned binary.
- Run
skaffold fixwhen you upgrade Skaffold and commit the change.