Skip to content
Latchkey

Skaffold "skaffold config file not found" in CI

Skaffold looks for skaffold.yaml in the current working directory (or the path given with -f/--filename). In CI the checkout root or a subdirectory layout often means the file is not where Skaffold looks.

What this error means

Any skaffold command fails at once with "skaffold config file skaffold.yaml not found" before building or deploying.

skaffold
skaffold config file skaffold.yaml not found - check your current working directory,
or try running `skaffold init`

Common causes

Wrong working directory in the job

The config lives in a subfolder (for example deploy/) but the step runs from the repository root, so Skaffold sees no skaffold.yaml.

A non-default filename not passed with --filename

The config is named something other than skaffold.yaml and the command does not point at it with -f.

How to fix it

Point Skaffold at the config explicitly

Pass the path with -f so the working directory does not matter.

Terminal
skaffold run -f deploy/skaffold.yaml

Set the working directory for the step

  1. Confirm where skaffold.yaml lives in the repository.
  2. Set working-directory on the step (or cd into that folder).
  3. Re-run so Skaffold finds the default filename.
.github/workflows/ci.yml
- name: Deploy
  working-directory: deploy
  run: skaffold run

How to prevent it

  • Pass -f with an explicit path in CI so location is unambiguous.
  • Keep skaffold.yaml at a known, documented path.
  • Set working-directory on steps that assume a subfolder.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →