.gitlab-ci.yml invalid CI/CD Origin: Build & delivery Last updated 25 Oct 2026

GitLab CI: Found errors in your .gitlab-ci.yml: jobs:build config contains unknown keys: scripts

GitLab rejected the pipeline configuration, so no pipeline was created — the message names the job and the problem.

Exact message you may see Found errors in your .gitlab-ci.ymlconfig contains unknown keysjobs:build config should contain either a script, trigger or extends keywordchosen stage does not existyaml invalid GitLab CI
Seen on: GitLab CI

Meaning

The CI Lint tool (CI/CD → Editor → Validate, or Pipelines → CI lint) shows the exact error. Typical causes are unknown keys (scripts for script), a missing script, undefined stages or needs, wrong extends/include references, and YAML indentation.

Common causes

  • Misspelled key (scripts, stage: typo)
  • Job uses a stage that is not listed in stages:
  • needs: or extends: pointing to a job that does not exist
  • include: file path/project/ref wrong or not accessible
  • YAML indentation or quoting error

⚡ Quick fix

  1. Open CI/CD → Editor and press Validate to see the full error
  2. Compare stage names with the stages: list
  3. Check include: paths and project permissions

Detailed fix by platform

GitLab CI

  1. Lint via API: curl --header "PRIVATE-TOKEN: $TOKEN" "https://gitlab.com/api/v4/projects/$ID/ci/lint"

Code examples

Minimal valid job

yaml
stages: [build, test]
build:
  stage: build
  script:
    - make build

How to diagnose

  1. Message — Which job and key does GitLab name?
  2. Lint — Does CI Lint show more?
  3. Includes — All include paths reachable?

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: Build & delivery. Errors that are often confused with or caused by this one (click to open):

Cannot connect to the Docker daemon (GitLab) — GitLab CI: Cannot connect to the Docker daemon at tcp://docker:2375. Is the docker daemon running? (CI/CD)Cannot connect to the…compose validation — docker compose: services.x Additional property y is not allowed / yaml: line N: mapping values are not allowed (Docker)compose validationConfig compilation failed — CircleCI: Error calling workflow: 'build'. Cannot find a definition for job named test / Config does not conform to schema (CI/CD)Config compilation fa…depends on undefined service — service "web" depends on undefined service "db": invalid compose project (Docker)depends on undefined …ERROR: Job failed: exit code 1 — GitLab CI: ERROR: Job failed: exit code 1 (CI/CD)ERROR: Job failed: ex…Invalid workflow file — GitHub Actions: Invalid workflow file: .github/workflows/ci.yml#L12 — You have an error in your yaml syntax on line 12 (CI/CD)Invalid workflow fileJob depends on artifacts that have expired — GitLab CI: This job could not start because it could not retrieve the needed artifacts (dependencies: build). (CI/CD)Job depends on artifa…Pipeline filtered out by workflow:rules — GitLab CI: No pipeline created — pipeline filtered out by workflow:rules / "The rules configuration prevented any jobs from being added to the pipeline" (CI/CD)Pipeline filtered out….gitlab-c…

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.