1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-18 04:18:10 +00:00

ci: upload emulator binaries to data.trezor.io

[skip_ci]
This commit is contained in:
Martin Milata 2024-04-03 14:59:22 +02:00
parent c7832c39ab
commit fd23e3043d
2 changed files with 49 additions and 2 deletions

View File

@ -120,11 +120,12 @@ jobs:
- run: nix-shell --run "poetry run make -C core build_bootloader_emu"
if: matrix.coins == 'universal' && matrix.model != 'T3T1' # FIXME T3T1 bootloader emulator
- run: nix-shell --run "poetry run make -C core build_unix_frozen"
- run: cp core/build/unix/trezor-emu-core core/build/unix/trezor-emu-core-${{ matrix.model }}-${{ matrix.coins }}
- uses: actions/upload-artifact@v4
with:
name: core-emu-${{ matrix.model }}-${{ matrix.coins }}-${{ matrix.type }}-${{ matrix.asan }}
path: |
core/build/unix/trezor-emu-core
core/build/unix/trezor-emu-core*
core/build/bootloader_emu/bootloader.elf
retention-days: 7
@ -707,5 +708,25 @@ jobs:
- uses: ./.github/actions/ui-comment
if: ${{ steps.check-fixtures-changed.outputs.FIXTURES_CHANGED == '1' }}
core_upload_emu:
name: Upload emulator binaries
if: github.event_name == 'schedule'
runs-on: ubuntu-latest
needs: core_emu
steps:
- uses: actions/download-artifact@v4
with:
pattern: core-emu*debuglink-noasan
merge-multiple: true
- name: Configure aws credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::538326561891:role/gh_actions_deploy_dev_firmware_data
aws-region: eu-west-1
continue-on-error: true
- run: |
rm unix/trezor-emu-core
aws s3 sync unix s3://data.trezor.io/dev/firmware/emu-nightly
# Connect
# TODO: core_connect_test

View File

@ -3,6 +3,8 @@ name: Legacy
on:
pull_request:
workflow_dispatch:
schedule:
- cron: '35 22 * * *' # every day @ 22:35
permissions:
id-token: write # for fetching the OIDC token
@ -63,10 +65,13 @@ jobs:
submodules: recursive
- uses: ./.github/actions/environment
- run: nix-shell --run "poetry run legacy/script/cibuild"
- run: cp legacy/firmware/trezor.elf legacy/firmware/trezor-emu-legacy-T1B1-${{ matrix.coins }}
- uses: actions/upload-artifact@v4
with:
name: legacy-emu-${{ matrix.coins }}-${{ matrix.type }}-${{ matrix.asan }}
path: legacy/firmware/*.elf
path: |
legacy/firmware/*.elf
legacy/firmware/trezor-emu-legacy*
retention-days: 7
legacy_device_test:
@ -195,3 +200,24 @@ jobs:
id: check-fixtures-changed
- uses: ./.github/actions/ui-comment
if: ${{ steps.check-fixtures-changed.outputs.FIXTURES_CHANGED == '1' }}
core_upload_emu:
name: Upload emulator binaries
if: github.event_name == 'schedule'
runs-on: ubuntu-latest
needs: legacy_emu
steps:
- uses: actions/download-artifact@v4
with:
pattern: legacy-emu*debuglink-noasan
merge-multiple: true
- name: Configure aws credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::538326561891:role/gh_actions_deploy_dev_firmware_data
aws-region: eu-west-1
continue-on-error: true
- run: |
mkdir emulators
cp trezor-emu-legacy* emulators
aws s3 sync emulators s3://data.trezor.io/dev/firmware/emu-nightly