Overriding docker entrypoint with runs.entrypoint

I have a Dockerfile without an entrypoint, and I’m defining an action with:

runs:
  using: 'docker'
  image: './../../../Dockerfile'
  entrypoint: 'entrypoint.sh'

According to the documentation, the entrypoint option is supposed to override the docker entrypoint. However, that doesn’t happen:

/usr/bin/docker run --name ec5e102267eac6f850e5e2ae674a50bf9349_78f5b2 --label 20ec5e --workdir /github/workspace --rm -e INPUT_REPO-TOKEN -e HOME -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/actions-playground/actions-playground":"/github/workspace" 20ec5e:102267eac6f850e5e2ae674a50bf9349

What am I missing?

1 Like

Hey @duarten,

Thank you for being here and apologies for the delay, with the information you’ve provided here we are unable to reproduce. If this is still an issue would you mind sharing public repo with a full example illustrating this?

Can you give me a link to where you see that documented?

The documentation we have up on help.github.com has entrypoint under with https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepswithentrypoint

I meet the same problem.

I wrote action.yml:

name: entrypoint test
description: 'override entrypoint'
runs:
  using: 'docker'
  image: 'docker://alpine:3.10'
  entrypoint: ./.github/actions/entrypoint.sh
  args: ['echo', 'entrypoint was not overridden']

runs.entrypoint is specified, but is not applied. Is it working?

https://github.com/ww24/actions/commit/63d65a6351414d1b5431e817383a36b64db6ac40/checks

document: https://help.github.com/en/articles/metadata-syntax-for-github-actions#entrypoint 

3 Likes

Same issue. @chrispat any news on this?

This issue should have been fixed a few months back. :slight_smile:

Please let me know if the bug still exists. 

I just tried this today and I’m experiencing the exact same problem.

Action:

name: unitd build
description: 'Build unitd'
runs:
using: docker
image: Dockerfile
entrypoint: /usr/bin/echo
args:
- '--version'

result:

/usr/bin/docker run --name e87b52f598408aaed15fe600eb546c809dd5f0_e15286 --label e87b52 --workdir /github/workspace --rm -e HOME -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/github-actions/github-actions":"/github/workspace" e87b52:f598408aaed15fe600eb546c809dd5f0
2020/03/10 09:40:09 [alert] 1#1 Unable to create certificates storage directory: mkdir(state/certs/) failed (2: No such file or directory)
2020/03/10 09:40:09 [info] 1#1 unit started