3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request from qowoz/tf-update-action

.github/workflows/update-terraform-providers.yml: re-enable
This commit is contained in:
Jörg Thalheim 2022-10-07 10:29:27 +02:00 committed by GitHub
commit 3b1c9ca17a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 15 deletions
.github/workflows
pkgs/applications/networking/cluster/terraform-providers

View file

@ -1,8 +1,8 @@
name: "Update terraform-providers" name: "Update terraform-providers"
on: on:
#schedule: schedule:
# - cron: "14 3 * * 0" - cron: "0 3 * * *"
workflow_dispatch: workflow_dispatch:
permissions: permissions:
@ -28,10 +28,11 @@ jobs:
run: | run: |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config user.name "github-actions[bot]" git config user.name "github-actions[bot]"
pushd pkgs/applications/networking/cluster/terraform-providers nix-shell \
./update-all-providers --no-build maintainers/scripts/update.nix \
git commit -m "${{ steps.setup.outputs.title }}" providers.json --argstr commit true \
popd --argstr keep-going true \
--argstr path terraform-providers
- name: create PR - name: create PR
uses: peter-evans/create-pull-request@v4 uses: peter-evans/create-pull-request@v4
with: with:
@ -44,13 +45,5 @@ jobs:
``` ```
branch: terraform-providers-update branch: terraform-providers-update
delete-branch: false delete-branch: false
labels: "2.status: work-in-progress"
title: ${{ steps.setup.outputs.title }} title: ${{ steps.setup.outputs.title }}
token: ${{ secrets.GITHUB_TOKEN }} token: ${{ secrets.GITHUB_TOKEN }}
- name: comment on failure
uses: peter-evans/create-or-update-comment@v2
if: ${{ failure() }}
with:
issue-number: 153416
body: |
Automatic update of terraform providers [failed](https://github.com/NixOS/nixpkgs/actions/runs/${{ github.run_id }}).

View file

@ -52,7 +52,7 @@ let
passthru = attrs // { passthru = attrs // {
updateScript = writeShellScript "update" '' updateScript = writeShellScript "update" ''
provider="$(basename ${provider-source-address})" provider="$(basename ${provider-source-address})"
./pkgs/applications/networking/cluster/terraform-providers/update-provider --no-build "$provider" ./pkgs/applications/networking/cluster/terraform-providers/update-provider "$provider"
''; '';
}; };
}); });