# GitLab loadimpact/k6 docker image : unknown command \\"sh\\" for \\"k6\\"

**URL:** <https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579>\
**Category:** OSS Support\
**Created:** [May 7, 2019, 1:18pm UTC](https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579 "2019-05-07T13:18:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Murat](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/murat/32/34891_2.png) [@Murat](https://community.grafana.com/u/Murat)\
**Post date:** [May 7, 2019, 1:18pm UTC](https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579/1 "2019-05-07T13:18:16Z")

</div>

Using the docker image [https://hub.docker.com/r/loadimpact/k6/](https://hub.docker.com/r/loadimpact/k6/).

There are no instructions, but a simple yml file is configured for GitLab.  
We are blocked by a message: \* level=error msg=“unknown command "sh" for "k6"”\*

```yml
loadtest:
  stage: performance-test
  image: loadimpact/k6
  only:
      - k6test
  script:
    - pwd
    - k6 run k6-performance/getSites.js
  cache: {}
  tags:
    - DOCKER
    - NOPROXY
    - CLOUD

```

![Capture](https://us1.discourse-cdn.com/grafana/original/1X/2b31b30f95729420a529f5d6799a957104a4cf28.jpeg)

---

<div class="post-metadata">

**Author:** ![Murat](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/murat/32/34891_2.png) [@Murat](https://community.grafana.com/u/Murat)\
**Post date:** [May 7, 2019, 1:53pm UTC](https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579/2 "2019-05-07T13:53:06Z")

</div>

> [@Murat](#):
>
> k6 run k6-performance/getSites.js

same results with script : ‘k6 run ./k6-performance/getSites.js’ .

---

<div class="post-metadata">

**Author:** ![nedyalko](https://avatars.discourse-cdn.com/v4/letter/n/d26b3c/32.png) [@nedyalko](https://community.grafana.com/u/nedyalko)\
**Post date:** [May 7, 2019, 2:26pm UTC](https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579/3 "2019-05-07T14:26:11Z")

</div>

Since the [`ENTRYPOINT`](https://docs.docker.com/engine/reference/builder/#entrypoint) of [k6’s Dockerfile is `k6`](https://github.com/loadimpact/k6/blob/master/Dockerfile#L10), you’d need to overwrite it in the GitLab CI file to be able to execute the commands you’ve specified in the `script` list. You can do it like this: [Run your CI/CD jobs in Docker containers | GitLab](https://docs.gitlab.com/ee/ci/docker/using_docker_images.html#overriding-the-entrypoint-of-an-image)

---

<div class="post-metadata">

**Author:** ![Murat](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/murat/32/34891_2.png) [@Murat](https://community.grafana.com/u/Murat)\
**Post date:** [May 7, 2019, 2:49pm UTC](https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579/4 "2019-05-07T14:49:28Z")

</div>

Pipeline still chokes with same output error.

```yml
loadtest:
  stage: performance-test
  image:
    name: loadimpact/k6
    entrypoint: ["k6"]
  only:
      - k6test
  script:
    - k6 run ./k6-performance/getSites.js
  cache: {}
  tags:
    - DOCKER
    - NOPROXY
    - CLOUD

```

---

<div class="post-metadata">

**Author:** ![Murat](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/murat/32/34891_2.png) [@Murat](https://community.grafana.com/u/Murat)\
**Post date:** [May 7, 2019, 2:53pm UTC](https://community.grafana.com/t/gitlab-loadimpact-k6-docker-image-unknown-command-sh-for-k6/97579/5 "2019-05-07T14:53:35Z")

</div>

Set entrypoint as empty and that worked!

```yml
loadtest:
  stage: performance-test
  image:
    name: loadimpact/k6
    entrypoint: [""]
  only:
      - k6test
  script:
    - k6 run ./k6-performance/getSites.js
  cache: {}
  tags:
    - DOCKER
    - NOPROXY
    - CLOUD

```
