Skip to content

Args not being passed to action hosted as container on dockerhub #25084

Answered by weide-zhou
brettcannon asked this question in Actions
Discussion options

You must be logged in to vote

It’s not supported to set self-defined ‘repo-token’ in ‘jobs.<job_id>.steps.with’ for docker image.

With docker image while not action in ‘uses’, workflow will pull the docker image from public docker hub. According to the syntax doc, you can use ‘jobs.<job_id>.steps.with.args’ to pass a command to execute your script, but however cannot set input for the docker image.

Code sample as below:

name: my workflow
on: push
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@master
      - name: Check container
        uses: docker://alpine:3.8
        with:
          args: /bin/sh -c "cat /etc/alpine-release"

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants