Skip to content

Commit

Permalink
Fix updatecli workflow (#666)
Browse files Browse the repository at this point in the history
  • Loading branch information
gionn authored Jun 26, 2024
1 parent a28af45 commit 4220676
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
19 changes: 12 additions & 7 deletions .github/workflows/updatecli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,14 @@ on:
workflow_dispatch:
schedule:
- cron: '0 6 * * 1'
push:
paths:
- '.updatecli/**'
- .github/workflows/updatecli.yml

permissions:
contents: "write"
pull-requests: "write"
contents: write
pull-requests: write
id-token: write # This is required for requesting the JWT
deployments: write # This is required for deployment statuses management

Expand Down Expand Up @@ -38,9 +42,10 @@ jobs:
- uses: updatecli/updatecli-action@eb158f6fd9e425b940a6750d6318f98e050ac390 # v2.61.0

- name: Run Updatecli
run: "updatecli apply -c .updatecli/templates/github_releases.yaml -v .updatecli/values/github_releases/${{ matrix.file }}"
run: updatecli apply -c .updatecli/templates/github_releases.yaml -v .updatecli/values/github_releases/${{ matrix.file }}
env:
UPDATECLI_GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
USERNAME: ${{ github.actor }}
OWNER: ${{ github.repository_owner }}
REPOSITORY: ${{ github.event.repository.name }}
UPDATECLI_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
UPDATECLI_USERNAME: ${{ github.actor }}
UPDATECLI_REPO_OWNER: ${{ github.repository_owner }}
UPDATECLI_REPO_NAME: ${{ github.event.repository.name }}
UPDATECLI_REPO_BRANCH: ${{ github.event.repository.default_branch }}
8 changes: 4 additions & 4 deletions .updatecli/templates/github_releases.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ scms:
github:
kind: 'github'
spec:
username: '{{ requiredEnv "USERNAME" }}'
username: '{{ requiredEnv "UPDATECLI_USERNAME" }}'
token: '{{ requiredEnv "UPDATECLI_GITHUB_TOKEN" }}'
owner: '{{ requiredEnv "OWNER" }}'
repository: '{{ requiredEnv "REPOSITORY" }}'
branch: 'main'
owner: '{{ requiredEnv "UPDATECLI_REPO_OWNER" }}'
repository: '{{ requiredEnv "UPDATECLI_REPO_NAME" }}'
branch: '{{ requiredEnv "UPDATECLI_REPO_BRANCH" }}'
commitmessage:
type: '{{ .github.prefix }}'
message: '{{ .github.message }}'
Expand Down

0 comments on commit 4220676

Please sign in to comment.