From 3316d89ef9fcffe0976bd6ef091b74369b11044b Mon Sep 17 00:00:00 2001 From: Marco Ippolito Date: Mon, 15 May 2023 14:47:27 +0200 Subject: [PATCH] tools: open issue when update workflow fails --- .github/ISSUE_TEMPLATE/failed-dep-update.yml | 7 +++++++ .github/workflows/tools.yml | 10 ++++++++++ 2 files changed, 17 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/failed-dep-update.yml diff --git a/.github/ISSUE_TEMPLATE/failed-dep-update.yml b/.github/ISSUE_TEMPLATE/failed-dep-update.yml new file mode 100644 index 00000000000000..953641fbef8f60 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/failed-dep-update.yml @@ -0,0 +1,7 @@ +name: 'deps: update {{ env.FAILED_DEP }} job failed' +labels: dependencies +description: | + This is an automatically generated issue by + the {{ tools.context.action }} GitHub Action. + The update workflow has failed for {{ tools.context.workflow }}. + @nodejs/security-wg diff --git a/.github/workflows/tools.yml b/.github/workflows/tools.yml index ee596784db20f3..008677d835fd57 100644 --- a/.github/workflows/tools.yml +++ b/.github/workflows/tools.yml @@ -296,3 +296,13 @@ jobs: labels: ${{ matrix.label }} title: '${{ matrix.subsystem }}: update ${{ matrix.id }} to ${{ env.NEW_VERSION }}' update-pull-request-title-and-body: true + - name: Open issue on fail + id: create-issue + if: github.event_name == 'schedule' || inputs.id == 'all' || inputs.id == matrix.id && ${{ failure() }} + uses: JasonEtco/create-an-issue@e27dddc79c92bc6e4562f268fffa5ed752639abd + env: + GITHUB_TOKEN: ${{ secrets.GH_USER_TOKEN }} + FAILED_DEP: ${{ matrix.id }} + with: + filename: .github/ISSUE_TEMPLATE/failed-dep-update.md + update_existing: true