From 39f4287880d2d82187cb10b150a8d69a0a9d7404 Mon Sep 17 00:00:00 2001 From: Alexandr Kazachenko Date: Thu, 11 Jan 2024 17:24:06 +0600 Subject: [PATCH] chore: add env vars for Explorer --- .github/workflows/vercel.yml | 9 +++++++++ apps/explorer/src/components/analytics/index.ts | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/vercel.yml b/.github/workflows/vercel.yml index 6ca07c3613..d06ba11a5a 100644 --- a/.github/workflows/vercel.yml +++ b/.github/workflows/vercel.yml @@ -41,6 +41,7 @@ jobs: - name: Build Project Artifacts run: > + # CoWSwap env vars REACT_APP_SENTRY_DSN=${{ secrets.SENTRY_DSN }} REACT_APP_PINATA_API_KEY=${{ secrets.REACT_APP_PINATA_API_KEY }} REACT_APP_PINATA_SECRET_API_KEY=${{ secrets.REACT_APP_PINATA_SECRET_API_KEY }} @@ -53,6 +54,14 @@ jobs: REACT_APP_NETWORK_URL_5=${{ secrets.REACT_APP_NETWORK_URL_5 }} REACT_APP_NETWORK_URL_11155111=${{ secrets.REACT_APP_NETWORK_URL_11155111 }} REACT_APP_WC_PROJECT_ID=${{ secrets.REACT_APP_WC_PROJECT_ID }} + # Explorer env vars + REACT_APP_IPFS_READ_URI=${{ secrets.REACT_APP_IPFS_READ_URI }} + REACT_APP_SENTRY_DSN=${{ secrets.SENTRY_DSN }} + REACT_APP_SENTRY_AUTH_TOKEN=${{ secrets.SENTRY_AUTH_TOKEN }} + REACT_APP_EXPLORER_GOOGLE_ANALYTICS_ID=${{ secrets.EXPLORER_GOOGLE_ANALYTICS_ID }} + REACT_APP_SUBGRAPH_URL_MAINNET=${{ secrets.REACT_APP_SUBGRAPH_URL_MAINNET }} + REACT_APP_SUBGRAPH_URL_GNOSIS_CHAIN=${{ secrets.REACT_APP_SUBGRAPH_URL_GNOSIS_CHAIN }} + REACT_APP_SUBGRAPH_URL_GOERLI=${{ secrets.REACT_APP_SUBGRAPH_URL_GOERLI }} vercel build -t ${{ secrets.VERCEL_TOKEN }} --prod - name: Get the version diff --git a/apps/explorer/src/components/analytics/index.ts b/apps/explorer/src/components/analytics/index.ts index 0aeb3e2aa8..b04821e3e1 100644 --- a/apps/explorer/src/components/analytics/index.ts +++ b/apps/explorer/src/components/analytics/index.ts @@ -8,7 +8,7 @@ import { getCLS, getFCP, getFID, getLCP, Metric } from 'web-vitals' import GoogleAnalyticsProvider from './GoogleAnalyticsProvider' -const GOOGLE_ANALYTICS_ID: string | undefined = process.env.GOOGLE_ANALYTICS_ID +const GOOGLE_ANALYTICS_ID: string | undefined = process.env.REACT_APP_EXPLORER_GOOGLE_ANALYTICS_ID export const GOOGLE_ANALYTICS_CLIENT_ID_STORAGE_KEY = 'ga_client_id' const storedClientId = window.localStorage.getItem(GOOGLE_ANALYTICS_CLIENT_ID_STORAGE_KEY)