Basic pipeline only run one stage

Hi ! I’m running GitLab CE 18.3 self-hosted and after successfully configuring one Docker runner, i’m facing an issue with my first configured pipeline.

Here’s the step I followed:

  1. Setting up the runner on Docker
# Runner registration 
docker run --rm -it \
  -v gitlab-runner-config:/etc/gitlab-runner \
  gitlab/gitlab-runner:latest register \
  --non-interactive \
  --url "http://my_url.com" \
  --token "$AUTH_TOKEN" \
  --executor "docker" \
  --docker-image alpine:latest \
  --description "docker-runner for Packer"

# Permanent runner :
docker run -d --name gitlab-runner-packer --restart always \
  -v gitlab-runner-config:/etc/gitlab-runner \
  -v /var/run/docker.sock:/var/run/docker.sock \
  gitlab/gitlab-runner:latest

Runner configuration from Gitlab perspective, there’s only “Run untagged jobs” ticked :

  1. Create a basic gitlab-ci.yml as mentionned here , so 4 jobs should run after any commit and push on my branch.
build-job:
  stage: build
  script:
    - echo "Hello, $GITLAB_USER_LOGIN!"

test-job1:
  stage: test
  script:
    - echo "This job tests something"

test-job2:
  stage: test
  script:
    - echo "This job tests something, but takes more time than test-job1."
    - echo "After the echo commands complete, it runs the sleep command for 20 seconds"
    - echo "which simulates a test that runs 20 seconds longer than test-job1"
    - sleep 20

deploy-prod:
  stage: deploy
  script:
    - echo "This job deploys something from the $CI_COMMIT_BRANCH branch."
  environment: production
  1. Commit and push a basic modification on my project

  2. Check pipeline and job execution, the first job only is properly executed, but there’s nothing about others.

I tried to unregister/register again the runner (also delete docker volumes), clean runner cache but still the same result.

How can I troubleshoot this ? :slight_smile:

Best regards

Gael

Found out that the gitlab-ci.yml should be encoded as UTF-8 and not UTF-8BOM as my default VSCodium setting.

Everything runs fine ! :slight_smile: