Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Upload snapshots to s3 #2321

Merged
merged 12 commits into from
Jul 24, 2024
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ jobs:
target: aarch64-unknown-linux-gnu
runner: linux-arm64-c-2xlarge

permissions:
nahsi marked this conversation as resolved.
Show resolved Hide resolved
contents: read
id-token: write
nahsi marked this conversation as resolved.
Show resolved Hide resolved

steps:
- name: Checkout repository
uses: actions/checkout@v4
Expand Down Expand Up @@ -90,3 +94,27 @@ jobs:
with:
name: nox-${{ matrix.arch }}
path: target/${{ matrix.target }}/${{ steps.profile.outputs.profile }}/nox

- name: Import secrets
uses: hashicorp/vault-action@v3.0.0
with:
url: https://vault.fluence.dev
path: jwt/github
role: ci
method: jwt
jwtGithubAudience: "https://github.com/fluencelabs"
jwtTtl: 300
secrets: |
kv/ci/fluence-artifacts id | AWS_ACCESS_KEY_ID ;
kv/ci/fluence-artifacts secret | AWS_SECRET_ACCESS_KEY

- name: Rename nox binary
run: |
mkdir s3
nahsi marked this conversation as resolved.
Show resolved Hide resolved
cp target/${{ matrix.target }}/${{ steps.profile.outputs.profile }}/nox s3/nox-${{ matrix.arch }}
Copy link
Member

@folex folex Jul 24, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
cp target/${{ matrix.target }}/${{ steps.profile.outputs.profile }}/nox s3/nox-${{ matrix.arch }}
cp "target/${{ matrix.target }}/${{ steps.profile.outputs.profile }}/nox" "s3/nox-${{ matrix.arch }}"

maybe? and in the next step, too

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need really cause no bash spaces or bash variables there


- name: Upload nox snapshot to s3
env:
AWS_REGION: eu-west-1
BRANCH: ${{ github.head_ref }}
run: aws s3 cp s3/nox-${{ matrix.arch }} s3://fluence-artifacts/nox/snapshots/${{ env.BRANCH }}/ --acl public-read
11 changes: 4 additions & 7 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,7 @@ jobs:
./docker/nox_SHA256_SUMS
tag_name: ${{ inputs.tag }}

- name: Upload nox binary to s3
uses: osiegmar/s3-publisher-action@v1
with:
bucket: fluence-artifacts
dir: ./docker
prefix: nox/${{ inputs.version }}
include: nox-*
- name: Upload nox binaries to s3
env:
AWS_REGION: eu-west-1
run: aws s3 sync docker/ s3://fluence-artifacts/nox/${{ inputs.version }}/ --acl public-read --exact-timestamps --delete --include "nox*"
Loading