From 5efc26d10d2bbf3e59313d32c927871975a4894e Mon Sep 17 00:00:00 2001 From: Hugo Montero Date: Fri, 3 May 2024 10:37:08 -0600 Subject: [PATCH 1/3] add job dependencies --- .github/workflows/build.yml | 27 ++++++++++++++++++++++++++- .github/workflows/tests.yml | 26 -------------------------- 2 files changed, 26 insertions(+), 27 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index bad32d82d..62db9e227 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -5,11 +5,36 @@ on: branches: [ "master", "feature/cli-installer-v2" ] # should change once we have a stable branch pull_request: branches: [ "master", "feature/cli-installer-v2" ] - +env: + E2E_DEVICE_ID: ${{ secrets.E2E_DEVICE_ID }} + E2E_DEVICE_NAME: ${{ secrets.E2E_DEVICE_NAME }} + E2E_DEVICE_PLATFORM_ID: ${{ secrets.E2E_DEVICE_PLATFORM_ID }} + E2E_DEVICE_PLATFORM_NAME: ${{ secrets.E2E_DEVICE_PLATFORM_NAME }} + E2E_FOREIGN_DEVICE_ID: ${{ secrets.E2E_FOREIGN_DEVICE_ID }} + E2E_FOREIGN_DEVICE_NAME: ${{ secrets.E2E_FOREIGN_DEVICE_NAME }} + E2E_FOREIGN_DEVICE_PLATFORM_ID: ${{ secrets.E2E_FOREIGN_DEVICE_PLATFORM_ID }} + E2E_FOREIGN_DEVICE_PLATFORM_NAME: ${{ secrets.E2E_FOREIGN_DEVICE_PLATFORM_NAME }} + E2E_FOREIGN_PASSWORD: ${{ secrets.E2E_FOREIGN_PASSWORD }} + E2E_FOREIGN_USERNAME: ${{ secrets.E2E_FOREIGN_USERNAME }} + E2E_PASSWORD: ${{ secrets.E2E_PASSWORD }} + E2E_PRODUCT_01_DEVICE_01_GROUP: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_GROUP }} + E2E_PRODUCT_01_DEVICE_01_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_ID }} + E2E_PRODUCT_01_DEVICE_01_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_NAME }} + E2E_PRODUCT_01_DEVICE_01_PLATFORM_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_PLATFORM_ID }} + E2E_PRODUCT_01_DEVICE_01_PLATFORM_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_PLATFORM_NAME }} + E2E_PRODUCT_01_DEVICE_02_GROUP: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_GROUP }} + E2E_PRODUCT_01_DEVICE_02_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_ID }} + E2E_PRODUCT_01_DEVICE_02_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_NAME }} + E2E_PRODUCT_01_DEVICE_02_PLATFORM_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_PLATFORM_ID }} + E2E_PRODUCT_01_DEVICE_02_PLATFORM_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_PLATFORM_NAME }} + E2E_PRODUCT_01_ID: ${{ secrets.E2E_PRODUCT_01_ID }} + E2E_PRODUCT_01_NAME: ${{ secrets.E2E_PRODUCT_01_NAME }} + E2E_USERNAME: ${{ secrets.E2E_USERNAME }} jobs: call-tests: uses: ./.github/workflows/tests.yml build: + needs: call-tests runs-on: ubuntu-latest # Choose an appropriate runner steps: - uses: actions/checkout@v3 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9ec48251d..316688e90 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,32 +1,6 @@ name: Run Tests on: [workflow_call] -env: - E2E_DEVICE_ID: ${{ secrets.E2E_DEVICE_ID }} - E2E_DEVICE_NAME: ${{ secrets.E2E_DEVICE_NAME }} - E2E_DEVICE_PLATFORM_ID: ${{ secrets.E2E_DEVICE_PLATFORM_ID }} - E2E_DEVICE_PLATFORM_NAME: ${{ secrets.E2E_DEVICE_PLATFORM_NAME }} - E2E_FOREIGN_DEVICE_ID: ${{ secrets.E2E_FOREIGN_DEVICE_ID }} - E2E_FOREIGN_DEVICE_NAME: ${{ secrets.E2E_FOREIGN_DEVICE_NAME }} - E2E_FOREIGN_DEVICE_PLATFORM_ID: ${{ secrets.E2E_FOREIGN_DEVICE_PLATFORM_ID }} - E2E_FOREIGN_DEVICE_PLATFORM_NAME: ${{ secrets.E2E_FOREIGN_DEVICE_PLATFORM_NAME }} - E2E_FOREIGN_PASSWORD: ${{ secrets.E2E_FOREIGN_PASSWORD }} - E2E_FOREIGN_USERNAME: ${{ secrets.E2E_FOREIGN_USERNAME }} - E2E_PASSWORD: ${{ secrets.E2E_PASSWORD }} - E2E_PRODUCT_01_DEVICE_01_GROUP: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_GROUP }} - E2E_PRODUCT_01_DEVICE_01_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_ID }} - E2E_PRODUCT_01_DEVICE_01_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_NAME }} - E2E_PRODUCT_01_DEVICE_01_PLATFORM_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_PLATFORM_ID }} - E2E_PRODUCT_01_DEVICE_01_PLATFORM_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_01_PLATFORM_NAME }} - E2E_PRODUCT_01_DEVICE_02_GROUP: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_GROUP }} - E2E_PRODUCT_01_DEVICE_02_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_ID }} - E2E_PRODUCT_01_DEVICE_02_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_NAME }} - E2E_PRODUCT_01_DEVICE_02_PLATFORM_ID: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_PLATFORM_ID }} - E2E_PRODUCT_01_DEVICE_02_PLATFORM_NAME: ${{ secrets.E2E_PRODUCT_01_DEVICE_02_PLATFORM_NAME }} - E2E_PRODUCT_01_ID: ${{ secrets.E2E_PRODUCT_01_ID }} - E2E_PRODUCT_01_NAME: ${{ secrets.E2E_PRODUCT_01_NAME }} - E2E_USERNAME: ${{ secrets.E2E_USERNAME }} - jobs: unit-test: runs-on: ${{ matrix.os }} From 54c5208483cbfdbf11aa0c698bbf687273c94756 Mon Sep 17 00:00:00 2001 From: Julien Vanier Date: Fri, 3 May 2024 13:01:02 -0400 Subject: [PATCH 2/3] Map aarch64 to amd64 in unix installer --- installer/unix/install-cli | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/installer/unix/install-cli b/installer/unix/install-cli index 1bfacb270..22ccfb30c 100644 --- a/installer/unix/install-cli +++ b/installer/unix/install-cli @@ -41,7 +41,13 @@ esac PROCESSOR=$(uname -m) case $PROCESSOR in x86_64) - ARCH="amd64" + ARCH="x64" + ;; + aarch64) + ARCH="arm64" + ;; + arm64) + ARCH="arm64" ;; arm*) ARCH="arm" From 831270c0887a2bdd44deef91330ee561b6dbf348 Mon Sep 17 00:00:00 2001 From: Julien Vanier Date: Fri, 3 May 2024 13:09:41 -0400 Subject: [PATCH 3/3] Build Linux ARM64 --- package.json | 3 ++- scripts/generate-manifest.js | 3 --- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 8822de127..1af8b41d3 100644 --- a/package.json +++ b/package.json @@ -169,7 +169,8 @@ "node16-macos-x64", "node16-macos-arm64", "node16-win-x64", - "node16-linux-arm" + "node16-linux-arm", + "node16-linux-arm64" ], "assets": [ "./assets/**", diff --git a/scripts/generate-manifest.js b/scripts/generate-manifest.js index 1aaddf411..52ba8ca1d 100644 --- a/scripts/generate-manifest.js +++ b/scripts/generate-manifest.js @@ -29,9 +29,6 @@ function parseFilename(filename) { if (parts.length > 3) { arch = parts[3].split('.')[0]; } - if (arch?.includes('arm')) { - arch = 'arm'; - } return { platform: platformMap[parts[2]] || parts[2], arch: arch // Removing file extension if present