cachix / cachix-action

Build software only once and put it in a global cache
https://cachix.org
Apache License 2.0
245 stars 41 forks source link

Add flag to allow failures #131

Closed elsirion closed 1 year ago

elsirion commented 1 year ago

A recent cachix outage broke our builds at fedimint. This should not be the case since we could just build from source or not push in this scenario.

There does not seem to be an easy way to make GH Actions ignore the failure of an action. If I was running things manually I'd just add a || true after the cachix command. Ideally this action would have an ignore_failure (default to false to maintain default behavior) flag that does exactly that.

domenkozar commented 1 year ago

That's a github feature to allow step failures, not sure it makes sense to re-implement it in this action.

sandydoo commented 1 year ago

For anyone looking this up in the future, you can use continue-on-error to let the job continue should the action fail:

- uses: cachix/cachix-action@v12
  continue-on-error: true
  with:
    name: my-cache
    authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'