Unable to use binary in GitHub workflow

Hi,

I’m trying to use a binary available in my container in a GitHub workflow. My yaml looks like this:

jobs:
  speed:
    name: Speed
    runs-on: ubuntu-latest
    defaults:
      run:
        working-directory: ${{ github.workspace }}
    container: armandgrillet/platinum-speed:latest
    steps:
    - uses: actions/checkout@v1
    - name: Try which
      run: which ack
    - name: Use ack
      run: ack test

The container, armandgrillet/platinum-speed:latest, is based on Ubuntu and has ack installed using apt-get install.

When running the workflow described above, the step Try which returns /usr/bin/ack as expected. However, when running the second step (which I tested by running a container using the same image as the one in the workflow), I get:

Run ack test
  ack test
  shell: sh -e {0}
##[error]Process completed with exit code 1.

What am I missing?

Hi @armandgrillet,

The error is due to command ‘ack’ doesn’t exit properly.
Please add ‘&exit 0’ to make sure it exits properly. Code sample as below:

    - name: Use ack
      run: |
        ack test & exit 0

ackcommand

Thanks