Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to retry another GitHub Action? #91

Open
ThePieMonster opened this issue Aug 7, 2022 · 6 comments
Open

How to retry another GitHub Action? #91

ThePieMonster opened this issue Aug 7, 2022 · 6 comments
Assignees

Comments

@ThePieMonster
Copy link

ThePieMonster commented Aug 7, 2022

If I have a GitHub Action for deploying content to Azure, how can I retry this deployment step if the deployment fails?

      - uses: nick-fields/retry@v2
        id: retry
        # see https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions#jobsjob_idcontinue-on-error
        continue-on-error: true
        with:
          timeout_seconds: 15
          max_attempts: 2
          retry_on: error
          command: node -e 'process.exit(99);'

      - name: 'Deploy to Azure Web App'
        id: deploy-to-webapp
        uses: azure/webapps-deploy@v2
        with:
          app-name: ${{ env.APP_NAME }}
          slot-name: 'Production'
          publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE }}
          package: ${{ env.APP_DIR }}
@andry81
Copy link

andry81 commented Aug 18, 2022

Interested in this too, but for the ad-m/github-push-action action. Needs to retry the entire job because the push could not be retried without the pull and so complete rerun. The Job error can happen on any step, but only the push error must trigger the retry.

@skrdgraph
Copy link

+1 for this feature.

@Maxersh
Copy link

Maxersh commented Jan 17, 2023

bump

@leovido
Copy link

leovido commented May 30, 2023

+1 for this feature.

@matteovivona
Copy link

I found this other Action for this specific scenario https://github.com/marketplace/actions/retry-action

@mikeage
Copy link

mikeage commented Nov 28, 2023

I found this other Action for this specific scenario https://github.com/marketplace/actions/retry-action

This looks promising, but it can't be set to retry based on an output value (e.g., if there's an exit code X retry, but not for Y). The repo here does, but doesn't work with actions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants