use aws runner

This commit is contained in:
techknowlogick 2023-02-27 14:42:57 +08:00
parent 8fcd56dc7b
commit 6cc53f16d8
1 changed files with 4 additions and 9 deletions

View File

@ -6,7 +6,7 @@ on:
jobs: jobs:
goreleaser: goreleaser:
runs-on: ubuntu-latest runs-on: aws
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
with: with:
@ -20,16 +20,11 @@ jobs:
with: with:
distribution: goreleaser-pro distribution: goreleaser-pro
version: latest version: latest
args: release --nightly --skip-publish args: release --nightly
env: env:
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }} GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}
- name: publish to s3
run: |
apt update -y && apt install -y python python3-pip
pip install awscli
rm dist/artifacts.json dist/metadata.json dist/config.yaml
aws s3 sync dist/ s3://${{ secrets.S3_BUCKET }}/act_runner/main/
env:
AWS_REGION: ${{ secrets.AWS_REGION }} AWS_REGION: ${{ secrets.AWS_REGION }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
S3_REGION: ${{ secrets.AWS_REGION }}
S3_BUCKET: ${{ secrets.AWS_BUCKET }}