GitLab Runner - Docker based CI Buld can't find /bin/sh
I have pulled gitlab/gitlab-runner docker image and created container then successfully registered specific runner.
The below is my .gitlab-ci.yml file
image: docker:latest
build:
stage: build
script:
- mvn clean package
I am trying to execute project CI-Build, But it is failing with below error.
Note: Maven package already installed in my runner docker container.
I have tried the below workarounds, but couldn’t able to fix it,
- .bashrc file added maven path
- .gitlab-ci.yml file also added the maven home path.
- In .gitlab-ci.yml file tried various shell commands, But it is not recognizing.