Zarf Injector Rust Binaries #78
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: Zarf Injector Rust Binaries | |
permissions: | |
contents: read | |
id-token: write | |
on: | |
workflow_dispatch: | |
inputs: | |
versionTag: | |
description: "Version tag" | |
required: true | |
jobs: | |
build-injector: | |
runs-on: ubuntu-latest | |
steps: | |
- name: "Checkout Repo" | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | |
- name: Install tools | |
uses: ./.github/actions/install-tools | |
- name: "Build Rust Binary for x86_64 and arm64" | |
run: | | |
cd src/injector | |
make build-injector-linux | |
cd target | |
mkdir -p ../dist | |
cp x86_64-unknown-linux-musl/release/zarf-injector ../dist/zarf-injector-amd64 | |
cp aarch64-unknown-linux-musl/release/zarf-injector ../dist/zarf-injector-arm64 | |
cd ../dist | |
shasum zarf-injector-amd64 >> checksums.txt | |
shasum zarf-injector-arm64 >> checksums.txt | |
- name: Auth with AWS | |
uses: aws-actions/configure-aws-credentials@010d0da01d0b5a38af31e9c3470dbfdabdecca3a # v4.0.1 | |
with: | |
role-to-assume: ${{ secrets.AWS_WRITE_ROLE }} | |
role-session-name: ${{ github.job || github.event.client_payload.pull_request.head.sha || github.sha }} | |
aws-region: us-east-2 | |
role-duration-seconds: 3600 | |
- name: Sync Artifacts to S3 | |
run: | | |
aws s3 sync src/injector/dist/ s3://zarf-init/injector/${{ github.event.inputs.versionTag }}/ |