Skip to content

Commit 515f838

Browse files
authored
Merge pull request #97 from rafaelbreno/add-republish-latest-action
Add `republish-latest` action
2 parents f5e906f + f1c41b1 commit 515f838

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Republish Latest
2+
on:
3+
push:
4+
branches:
5+
- main
6+
paths:
7+
- 'Dockerfile'
8+
workflow_dispatch:
9+
10+
permissions:
11+
contents: write
12+
id-token: write
13+
14+
jobs:
15+
sync:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- name: "Read Secrets"
19+
uses: rancher-eio/read-vault-secrets@main
20+
with:
21+
secrets: |
22+
secret/data/github/repo/${{ github.repository }}/github/rancher-release-team-auto-tagger/app-credentials appId | APP_ID ;
23+
secret/data/github/repo/${{ github.repository }}/github/rancher-release-team-auto-tagger/app-credentials privateKey | PRIVATE_KEY
24+
25+
- name: Generate GitHub App token
26+
id: generate-token
27+
uses: actions/create-github-app-token@v2
28+
with:
29+
app-id: ${{ env.APP_ID }}
30+
private-key: ${{ env.PRIVATE_KEY }}
31+
32+
- name: Republish Latest Release
33+
uses: rancher/ecm-distro-tools/actions/republish-latest@master
34+
with:
35+
owner: ${{ github.repository_owner }}
36+
repo: ${{ github.event.repository.name }}
37+
commitish: 'main'
38+
GH_TOKEN: ${{ steps.generate-token.outputs.token }}

0 commit comments

Comments
 (0)