Troubleshooting Service runner didn't start properly
After I commit some to my staging branch in MadeByThePinsTeam-DevLabs/contributing (see commit ID bad7ecf83b1e6a4becf1d48d6701878f32463aa0), some errors where found in the logs as I ran manual dry run for triage. What should I do on my side to fix these errors?
Additional information
The additional information are provided for you if you need to reproduce the issue.
Gitlab CI Config file
# Use the latest Docker version for Alpine Linux to keep safe.
image: alpine:latest
# Next, install Ruby and Python.
services:
- ruby:latest
- python:latest
# Define the stages that needed for CI to run.
stages:
- pages
- triage
# Set the variables here. Try to avoid commiting any secrets here or elsewhere where the public can sees.
variables:
# For our security, our API_TOKEN is hidden from the public.
# To use it for your own forks, change it in the UI. See docs for details.
# API_TOKEN: <insert here with caution>
# Change 15542288 to your project's ID if your team is always changing slugs.
CI_PROJECT_PATH: 15542288
mkdocs:
stage: pages
script:
- pip install mkdocs
- pip install mkdocs-material
- mkdocs build
- mv site public
artifacts:
paths:
- public
only:
- master
dry-run:triage:
stage: triage
script:
- echo GitLab Runners are ready to go! Hang on...
- echo Installing gitlab-triage package...
- gem install gitlab-triage
- echo Successfully installed! Testing the installation...
- gitlab-triage --help
- echo The installation was tested sucessfully. Running dry-run scripts...
- gitlab-triage --dry-run --token $API_TOKEN --source-id $CI_PROJECT_PATH
- echo The dry-run scripts should be successfully passed. Otherwise, create an new GitLab issue instead.
when: manual
except:
- schedules
run:triage:
stage: triage
script:
- echo GitLab Runners are ready to go! Hang on...
- echo Installing gitlab-triage package...
- gem install gitlab-triage
- echo Successfully installed! Hold tight, we're setting things up...
- echo To test your GitLab Triage installation, please trigger an new dry-run job instead.
- echo Checks are now completed, running scripts...
- gitlab-triage --token $API_TOKEN --source-id $CI_PROJECT_PATH
- echo It should be successfully passed. Otherwise, create an new issue.
only:
- schedules
Raw logs
[0KRunning with gitlab-runner 12.5.0-rc1 (b295d93b)
[0;m[0K on docker-auto-scale fa6cab46
[0;msection_start:1575184855:prepare_executor
[0K[0KUsing Docker executor with image alpine:latest ...
[0;m[0KStarting service ruby:latest ...
[0;m[0KPulling docker image ruby:latest ...
[0;m[0KUsing docker image sha256:2ff4e698f315bc2e8538bd154dcb84d5e277994660fde250879ee2de0f780e28 for ruby:latest ...
[0;m[0KStarting service python:latest ...
[0;m[0KPulling docker image python:latest ...
[0;m[0KUsing docker image sha256:0a3a95c81a2bd8d2ee9653097a4e0ae63d8765636874083afb5e9a7d52b6b9f1 for python:latest ...
[0;m[0KWaiting for services to be up and running...
[0;m
[0;33m*** WARNING:[0;m Service runner-fa6cab46-project-15542288-concurrent-0-ruby-0 probably didn't start properly.
Health check error:
ContainerStart: Error response from daemon: Cannot link to a non running container: /runner-fa6cab46-project-15542288-concurrent-0-ruby-0 AS /runner-fa6cab46-project-15542288-concurrent-0-ruby-0-wait-for-service/service (executor_docker.go:1254:0s)
Service container logs:
2019-12-01T07:21:35.716166395Z Switch to inspect mode.
2019-12-01T07:21:35.716816184Z
[0;33m*********[0;m
[0;33m*** WARNING:[0;m Service runner-fa6cab46-project-15542288-concurrent-0-python-1 probably didn't start properly.
Health check error:
ContainerStart: Error response from daemon: Cannot link to a non running container: /runner-fa6cab46-project-15542288-concurrent-0-python-1 AS /runner-fa6cab46-project-15542288-concurrent-0-python-1-wait-for-service/service (executor_docker.go:1254:0s)
Service container logs:
[0;33m*********[0;m
[0KPulling docker image alpine:latest ...
[0;m[0KUsing docker image sha256:965ea09ff2ebd2b9eeec88cd822ce156f6674c7e99be082c7efac3c62f3ff652 for alpine:latest ...
[0;msection_end:1575184902:prepare_executor
[0Ksection_start:1575184902:prepare_script
[0KRunning on runner-fa6cab46-project-15542288-concurrent-0 via runner-fa6cab46-srm-1575184807-3e026997...
section_end:1575184903:prepare_script
[0Ksection_start:1575184903:get_sources
[0K[32;1mFetching changes with git depth set to 50...[0;m
Initialized empty Git repository in /builds/MadeByThePinsTeam-DevLabs/contributing/.git/
[32;1mCreated fresh repository.[0;m
From https://gitlab.com/MadeByThePinsTeam-DevLabs/contributing
* [new ref] refs/pipelines/99742354 -> refs/pipelines/99742354
* [new branch] staging -> origin/staging
[32;1mChecking out bad7ecf8 as staging...[0;m
[32;1mSkipping Git submodules setup[0;m
section_end:1575184905:get_sources
[0Ksection_start:1575184905:restore_cache
[0Ksection_end:1575184906:restore_cache
[0Ksection_start:1575184906:download_artifacts
[0Ksection_end:1575184907:download_artifacts
[0Ksection_start:1575184907:build_script
[0K[32;1m$ echo GitLab Runners are ready to go! Hang on...[0;m
GitLab Runners are ready to go! Hang on...
[32;1m$ echo Installing gitlab-triage package...[0;m
Installing gitlab-triage package...
[32;1m$ gem install gitlab-triage[0;m
/bin/sh: eval: line 92: gem: not found
section_end:1575184909:build_script
[0Ksection_start:1575184909:after_script
[0Ksection_end:1575184910:after_script
[0Ksection_start:1575184910:upload_artifacts_on_failure
[0Ksection_end:1575184912:upload_artifacts_on_failure
[0K[31;1mERROR: Job failed: exit code 127
[0;m
Edited by Andrei Jiroh Eugenio Halili