Version 1.1.0 #23
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: TPGZ Release Automation | |
on: | |
release: | |
types: | |
- published | |
permissions: | |
id-token: write | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Download latest release patches | |
run: curl -s https://api.github.com/repos/zsrtp/tpgz/releases/latest | grep "http.*patch" | cut -d ":" -f 2,3 | tr -d \ \" | wget -qi - --directory-prefix patches/ | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ROLE_ARN }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download existing meta.json | |
run: aws s3 cp s3://${{ secrets.AWS_S3_BUCKET }}/patches/meta.json meta.json | |
- name: Update meta.json | |
run: | | |
python3 external/misc/meta.py | |
- name: Upload updated meta.json to S3 | |
run: aws s3 cp meta.json s3://${{ secrets.AWS_S3_BUCKET }}/patches/meta.json --acl public-read | |
- name: Sync directory to S3 | |
run: | | |
aws s3 sync patches/ s3://${{ secrets.AWS_S3_BUCKET }}/patches/ --acl public-read |