Skip to content

Export path

Export path #39

Workflow file for this run

name: Concordium desktop wallet release
on:
workflow_dispatch:
inputs:
service:
type: choice
description: Choose which workflow should be ran
options:
- desktop-wallet-windows
- release-desktop-wallet-linux
push:
branches:
- ekw/SRE-1001/release-desktop-wallet
tags:
- desktop-wallet-*/*
env:
BASE_IMAGE_VERSION: "rust-1.82_ghc-9.6.6-1"
STATIC_NODE_BINARY_IMAGE_NAME: 'static-node-binaries'
AWS_ROLE_TO_ASSUME: "arn:aws:iam::192549843005:role/github_concordium-desktop-wallet"
S3_BUCKET: "s3://desktopwallet.concordium.com/"
ECR_REPO: "192549843005.dkr.ecr.eu-west-1.amazonaws.com/concordium/desktop-wallet-ci"
permissions:
id-token: write
contents: read
jobs:
login-aws:
runs-on: ubuntu-latest
outputs:
access_key: ${{ steps.login-ecr.outputs.docker_username_192549843005_dkr_ecr_eu_west_1_amazonaws_com }}
secret_key: ${{ steps.login-ecr.outputs.docker_password_192549843005_dkr_ecr_eu_west_1_amazonaws_com }}
environment: release
steps:
- name: aws creds
uses: aws-actions/configure-aws-credentials@v4
id: creds
with:
aws-region: "eu-west-1"
role-to-assume: ${{ env.AWS_ROLE_TO_ASSUME }}
role-session-name: ReleaseDesktopWalletSession
mask-aws-account-id: false
- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v2
with:
mask-password: false
release-desktop-wallet-linux:
environment: release
needs: login-aws
runs-on: ubuntu-latest
container:
image: "192549843005.dkr.ecr.eu-west-1.amazonaws.com/concordium/desktop-wallet-ci:latest"
credentials:
username: ${{needs.login-aws.outputs.access_key}}
password: ${{needs.login-aws.outputs.secret_key}}
options: -u root
#services:
# internal-service:
# image: "192549843005.dkr.ecr.eu-west-1.amazonaws.com/concordium/desktop-wallet-ci:latest"
# credentials:
# username: ${{needs.login-aws.outputs.access_key}}
# password: ${{needs.login-aws.outputs.secret_key}}
# ports:
# - 80:80
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
ref: 'v1.7.4'
- name: install cargo
run: |
rustup toolchain install 1.68.2-x86_64-unknown-linux-gnu
rustup default 1.68.2
export PATH=$PATH:$HOME/.cargo:§HOME/.cargo:bin
- name: Install dependencies and build
run: |
TARGET_NET="stagenet"
node --version
npm --version
yarn --version
python --version
rustup show
wasm-pack --version
cargo --version
yarn
yarn package
# - name: publish
# run: |
# # Extract version number
# VERSION=$(awk '/"version":/ { print substr($2, 2, length($2)-3); exit }' app/package.json)
#
# # Prepare filenames
# if [[ $TARGET_NET = "mainnet" ]]; then
# FILENAME_DEB="concordium-desktop-wallet-${VERSION}.deb"
# FILENAME_RPM="concordium-desktop-wallet-${VERSION}.rpm"
# FILENAME_APPIMAGE="concordium-desktop-wallet-${VERSION}.AppImage"
# else
# FILENAME_DEB="concordium-desktop-wallet-${TARGET_NET}-${VERSION}.deb"
# FILENAME_RPM="concordium-desktop-wallet-${TARGET_NET}-${VERSION}.rpm"
# FILENAME_APPIMAGE="concordium-desktop-wallet-${TARGET_NET}-${VERSION}.AppImage"
# fi
#
# FILENAME_LATEST_LINUX="latest-linux.yml"
#
# OUT_FILENAME_DEB="${VERSION}/${TARGET_NET}/${FILENAME_DEB}"
# OUT_FILENAME_RPM="${VERSION}/${TARGET_NET}/${FILENAME_RPM}"
# OUT_FILENAME_APPIMAGE="${VERSION}/${TARGET_NET}/${FILENAME_APPIMAGE}"
# OUT_LATEST_LINUX="${VERSION}/${TARGET_NET}/latest-linux.yml"
#
# # Push to s3
# aws s3 cp "release/${FILENAME_DEB}" "${{env.S3_BUCKET}}/${OUT_FILENAME_DEB}" --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers
# aws s3 cp "release/${FILENAME_RPM}" "${{env.S3_BUCKET}}/${OUT_FILENAME_RPM}" --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers
# aws s3 cp "release/${FILENAME_APPIMAGE}" "${{env.S3_BUCKET}}/${OUT_FILENAME_APPIMAGE}" --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers
# aws s3 cp "release/${FILENAME_LATEST_LINUX}" "${{env.S3_BUCKET}}/${OUT_LATEST_LINUX}" --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers