From 3ffa114978c09ee3efc1cbdb884d6f9a88253087 Mon Sep 17 00:00:00 2001 From: Jack Hamer <47187316+JackHamer09@users.noreply.github.com> Date: Wed, 17 Jan 2024 16:15:24 +0200 Subject: [PATCH] fix: deploy to staging with env (#151) --- .github/workflows/release.yml | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e594dec0f..9205e88a8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -51,21 +51,25 @@ jobs: with: fetch-depth: 0 - - name: Download Dist package - uses: dsaltares/fetch-gh-release-asset@master + - name: Setup Node.js + uses: actions/setup-node@v3 with: - version: "tags/v${{ needs.publish.outputs.releaseVersion }}" - file: "dist.zip" - target: "dist.zip" - token: ${{ secrets.GITHUB_TOKEN }} + node-version: '18' + cache: 'npm' + + - name: Install dependencies + run: | + npm ci --force - - name: Unzip Dist package + - name: Setup .env run: | - unzip dist.zip + echo "WALLET_CONNECT_PROJECT_ID=${{ secrets.WALLET_CONNECT_PROJECT_ID }}" > .env + echo "ANKR_TOKEN=${{ secrets.ANKR_TOKEN }}" >> .env + echo "SCREENING_API_URL=${{ secrets.SCREENING_API_URL }}" >> .env - - name: Update config + - name: Build run: | - echo "window[\"##runtimeConfig\"] = { firebaseProjectId: \"staging-zksync-dapp-wallet-v2\", appEnvironment: \"staging\" };" > dist/config.js + npm run generate - name: Deploy uses: matter-labs/action-hosting-deploy@main