Skip to content

Commit

Permalink
fix: prefix environment variables (anoma#493)
Browse files Browse the repository at this point in the history
  • Loading branch information
emccorson committed Dec 11, 2023
1 parent 5f9db9a commit 570f068
Show file tree
Hide file tree
Showing 39 changed files with 225 additions and 225 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/deploy-wallet-at-merge-to-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ jobs:
working-directory: ./apps/namada-interface
run: yarn build
env:
REACT_APP_NAMADA_ALIAS: "Namada Devnet"
REACT_APP_NAMADA_CHAIN_ID: "internal-devnet-6be.86067e06a5"
REACT_APP_NAMADA_URL: "https://proxy.heliax.click/internal-devnet-6be.86067e06a5"
NAMADA_INTERFACE_NAMADA_ALIAS: "Namada Devnet"
NAMADA_INTERFACE_NAMADA_CHAIN_ID: "internal-devnet-6be.86067e06a5"
NAMADA_INTERFACE_NAMADA_URL: "https://proxy.heliax.click/internal-devnet-6be.86067e06a5"

- name: Deploy to Netlify
if: false
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/deploy-wallet-at-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,9 @@ jobs:
working-directory: ./apps/namada-interface
run: yarn build
env:
REACT_APP_NAMADA_ALIAS: "Namada Devnet"
REACT_APP_NAMADA_CHAIN_ID: "internal-devnet-6be.86067e06a5"
REACT_APP_NAMADA_URL: "https://proxy.heliax.click/internal-devnet-6be.86067e06a5"
NAMADA_INTERFACE_NAMADA_ALIAS: "Namada Devnet"
NAMADA_INTERFACE_NAMADA_CHAIN_ID: "internal-devnet-6be.86067e06a5"
NAMADA_INTERFACE_NAMADA_URL: "https://proxy.heliax.click/internal-devnet-6be.86067e06a5"
- name: Deploy to Netlify
uses: nwtgck/[email protected]
with:
Expand Down
146 changes: 73 additions & 73 deletions .github/workflows/release-wallet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,34 +6,34 @@ on:
required: true
type: string
default: "main"
REACT_APP_NAMADA_ALIAS:
NAMADA_INTERFACE_NAMADA_ALIAS:
required: true
type: string
default: "Namada Testnet"
REACT_APP_NAMADA_CHAIN_ID:
NAMADA_INTERFACE_NAMADA_CHAIN_ID:
required: true
type: string
REACT_APP_NAMADA_URL:
NAMADA_INTERFACE_NAMADA_URL:
required: true
type: string
REACT_APP_COSMOS_ALIAS:
NAMADA_INTERFACE_COSMOS_ALIAS:
required: false
type: string
default: "Cosmos Testnet"
REACT_APP_COSMOS_CHAIN_ID:
NAMADA_INTERFACE_COSMOS_CHAIN_ID:
required: false
type: string
REACT_APP_COSMOS_URL:
NAMADA_INTERFACE_COSMOS_URL:
required: false
type: string
REACT_APP_ETH_ALIAS:
NAMADA_INTERFACE_ETH_ALIAS:
required: false
type: string
default: "Goerli Testnet"
REACT_APP_ETH_CHAIN_ID:
NAMADA_INTERFACE_ETH_CHAIN_ID:
required: false
type: string
REACT_APP_ETH_URL:
NAMADA_INTERFACE_ETH_URL:
required: false
type: string

Expand Down Expand Up @@ -61,25 +61,25 @@ jobs:

- name: Print workflow inputs
run: |
echo "REACT_APP_NAMADA_ALIAS: $REACT_APP_NAMADA_ALIAS" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_NAMADA_CHAIN_ID: $REACT_APP_NAMADA_CHAIN_ID" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_NAMADA_URL: $REACT_APP_NAMADA_URL" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_COSMOS_ALIAS: $REACT_APP_COSMOS_ALIAS" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_COSMOS_CHAIN_ID: $REACT_APP_COSMOS_CHAIN_ID" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_COSMOS_URL: $REACT_APP_COSMOS_URL" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_ETH_ALIAS: $REACT_APP_ETH_ALIAS" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_ETH_CHAIN_ID: $REACT_APP_ETH_CHAIN_ID" >> $GITHUB_STEP_SUMMARY
echo "REACT_APP_ETH_URL: $REACT_APP_ETH_URL" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_NAMADA_ALIAS: $NAMADA_INTERFACE_NAMADA_ALIAS" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_NAMADA_CHAIN_ID: $NAMADA_INTERFACE_NAMADA_CHAIN_ID" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_NAMADA_URL: $NAMADA_INTERFACE_NAMADA_URL" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_COSMOS_ALIAS: $NAMADA_INTERFACE_COSMOS_ALIAS" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_COSMOS_CHAIN_ID: $NAMADA_INTERFACE_COSMOS_CHAIN_ID" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_COSMOS_URL: $NAMADA_INTERFACE_COSMOS_URL" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_ETH_ALIAS: $NAMADA_INTERFACE_ETH_ALIAS" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_ETH_CHAIN_ID: $NAMADA_INTERFACE_ETH_CHAIN_ID" >> $GITHUB_STEP_SUMMARY
echo "NAMADA_INTERFACE_ETH_URL: $NAMADA_INTERFACE_ETH_URL" >> $GITHUB_STEP_SUMMARY
env:
REACT_APP_NAMADA_ALIAS: ${{ inputs.REACT_APP_NAMADA_ALIAS }}
REACT_APP_NAMADA_CHAIN_ID: ${{ inputs.REACT_APP_NAMADA_CHAIN_ID }}
REACT_APP_NAMADA_URL: ${{ inputs.REACT_APP_NAMADA_URL }}
REACT_APP_COSMOS_ALIAS: ${{ inputs.REACT_APP_COSMOS_ALIAS }}
REACT_APP_COSMOS_CHAIN_ID: ${{ inputs.REACT_APP_COSMOS_CHAIN_ID }}
REACT_APP_COSMOS_URL: ${{ inputs.REACT_APP_COSMOS_URL }}
REACT_APP_ETH_ALIAS: ${{ inputs.REACT_APP_ETH_ALIAS }}
REACT_APP_ETH_CHAIN_ID: ${{ inputs.REACT_APP_ETH_CHAIN_ID }}
REACT_APP_ETH_URL: ${{ inputs.REACT_APP_ETH_URL }}
NAMADA_INTERFACE_NAMADA_ALIAS: ${{ inputs.NAMADA_INTERFACE_NAMADA_ALIAS }}
NAMADA_INTERFACE_NAMADA_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_NAMADA_CHAIN_ID }}
NAMADA_INTERFACE_NAMADA_URL: ${{ inputs.NAMADA_INTERFACE_NAMADA_URL }}
NAMADA_INTERFACE_COSMOS_ALIAS: ${{ inputs.NAMADA_INTERFACE_COSMOS_ALIAS }}
NAMADA_INTERFACE_COSMOS_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_COSMOS_CHAIN_ID }}
NAMADA_INTERFACE_COSMOS_URL: ${{ inputs.NAMADA_INTERFACE_COSMOS_URL }}
NAMADA_INTERFACE_ETH_ALIAS: ${{ inputs.NAMADA_INTERFACE_ETH_ALIAS }}
NAMADA_INTERFACE_ETH_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_ETH_CHAIN_ID }}
NAMADA_INTERFACE_ETH_URL: ${{ inputs.NAMADA_INTERFACE_ETH_URL }}

build-interface:
needs: setup
Expand All @@ -105,16 +105,16 @@ jobs:
working-directory: ./apps/namada-interface
run: yarn build
env:
REACT_APP_NAMADA_ALIAS: ${{ inputs.REACT_APP_NAMADA_ALIAS }}
REACT_APP_NAMADA_CHAIN_ID: ${{ inputs.REACT_APP_NAMADA_CHAIN_ID }}
REACT_APP_NAMADA_URL: ${{ inputs.REACT_APP_NAMADA_URL }}
REACT_APP_COSMOS_ALIAS: ${{ inputs.REACT_APP_COSMOS_ALIAS }}
REACT_APP_COSMOS_CHAIN_ID: ${{ inputs.REACT_APP_COSMOS_CHAIN_ID }}
REACT_APP_COSMOS_URL: ${{ inputs.REACT_APP_COSMOS_URL }}
REACT_APP_ETH_ALIAS: ${{ inputs.REACT_APP_ETH_ALIAS }}
REACT_APP_ETH_CHAIN_ID: ${{ inputs.REACT_APP_ETH_CHAIN_ID }}
REACT_APP_ETH_URL: ${{ inputs.REACT_APP_ETH_URL }}
REACT_APP_EXTENSION_URL: https://github.com/anoma/namada-interface/releases/tag/${{ needs.setup.outputs.VERSION }}/
NAMADA_INTERFACE_NAMADA_ALIAS: ${{ inputs.NAMADA_INTERFACE_NAMADA_ALIAS }}
NAMADA_INTERFACE_NAMADA_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_NAMADA_CHAIN_ID }}
NAMADA_INTERFACE_NAMADA_URL: ${{ inputs.NAMADA_INTERFACE_NAMADA_URL }}
NAMADA_INTERFACE_COSMOS_ALIAS: ${{ inputs.NAMADA_INTERFACE_COSMOS_ALIAS }}
NAMADA_INTERFACE_COSMOS_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_COSMOS_CHAIN_ID }}
NAMADA_INTERFACE_COSMOS_URL: ${{ inputs.NAMADA_INTERFACE_COSMOS_URL }}
NAMADA_INTERFACE_ETH_ALIAS: ${{ inputs.NAMADA_INTERFACE_ETH_ALIAS }}
NAMADA_INTERFACE_ETH_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_ETH_CHAIN_ID }}
NAMADA_INTERFACE_ETH_URL: ${{ inputs.NAMADA_INTERFACE_ETH_URL }}
NAMADA_INTERFACE_EXTENSION_URL: https://github.com/anoma/namada-interface/releases/tag/${{ needs.setup.outputs.VERSION }}/

- uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -149,15 +149,15 @@ jobs:
working-directory: ./apps/extension
run: yarn build:chrome
env:
REACT_APP_NAMADA_ALIAS: ${{ inputs.REACT_APP_NAMADA_ALIAS }}
REACT_APP_NAMADA_CHAIN_ID: ${{ inputs.REACT_APP_NAMADA_CHAIN_ID }}
REACT_APP_NAMADA_URL: ${{ inputs.REACT_APP_NAMADA_URL }}
REACT_APP_COSMOS_ALIAS: ${{ inputs.REACT_APP_COSMOS_ALIAS }}
REACT_APP_COSMOS_CHAIN_ID: ${{ inputs.REACT_APP_COSMOS_CHAIN_ID }}
REACT_APP_COSMOS_URL: ${{ inputs.REACT_APP_COSMOS_URL }}
REACT_APP_ETH_ALIAS: ${{ inputs.REACT_APP_ETH_ALIAS }}
REACT_APP_ETH_CHAIN_ID: ${{ inputs.REACT_APP_ETH_CHAIN_ID }}
REACT_APP_ETH_URL: ${{ inputs.REACT_APP_ETH_URL }}
NAMADA_INTERFACE_NAMADA_ALIAS: ${{ inputs.NAMADA_INTERFACE_NAMADA_ALIAS }}
NAMADA_INTERFACE_NAMADA_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_NAMADA_CHAIN_ID }}
NAMADA_INTERFACE_NAMADA_URL: ${{ inputs.NAMADA_INTERFACE_NAMADA_URL }}
NAMADA_INTERFACE_COSMOS_ALIAS: ${{ inputs.NAMADA_INTERFACE_COSMOS_ALIAS }}
NAMADA_INTERFACE_COSMOS_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_COSMOS_CHAIN_ID }}
NAMADA_INTERFACE_COSMOS_URL: ${{ inputs.NAMADA_INTERFACE_COSMOS_URL }}
NAMADA_INTERFACE_ETH_ALIAS: ${{ inputs.NAMADA_INTERFACE_ETH_ALIAS }}
NAMADA_INTERFACE_ETH_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_ETH_CHAIN_ID }}
NAMADA_INTERFACE_ETH_URL: ${{ inputs.NAMADA_INTERFACE_ETH_URL }}

- uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -192,15 +192,15 @@ jobs:
working-directory: ./apps/extension
run: yarn build:firefox
env:
REACT_APP_NAMADA_ALIAS: ${{ inputs.REACT_APP_NAMADA_ALIAS }}
REACT_APP_NAMADA_CHAIN_ID: ${{ inputs.REACT_APP_NAMADA_CHAIN_ID }}
REACT_APP_NAMADA_URL: ${{ inputs.REACT_APP_NAMADA_URL }}
REACT_APP_COSMOS_ALIAS: ${{ inputs.REACT_APP_COSMOS_ALIAS }}
REACT_APP_COSMOS_CHAIN_ID: ${{ inputs.REACT_APP_COSMOS_CHAIN_ID }}
REACT_APP_COSMOS_URL: ${{ inputs.REACT_APP_COSMOS_URL }}
REACT_APP_ETH_ALIAS: ${{ inputs.REACT_APP_ETH_ALIAS }}
REACT_APP_ETH_CHAIN_ID: ${{ inputs.REACT_APP_ETH_CHAIN_ID }}
REACT_APP_ETH_URL: ${{ inputs.REACT_APP_ETH_URL }}
NAMADA_INTERFACE_NAMADA_ALIAS: ${{ inputs.NAMADA_INTERFACE_NAMADA_ALIAS }}
NAMADA_INTERFACE_NAMADA_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_NAMADA_CHAIN_ID }}
NAMADA_INTERFACE_NAMADA_URL: ${{ inputs.NAMADA_INTERFACE_NAMADA_URL }}
NAMADA_INTERFACE_COSMOS_ALIAS: ${{ inputs.NAMADA_INTERFACE_COSMOS_ALIAS }}
NAMADA_INTERFACE_COSMOS_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_COSMOS_CHAIN_ID }}
NAMADA_INTERFACE_COSMOS_URL: ${{ inputs.NAMADA_INTERFACE_COSMOS_URL }}
NAMADA_INTERFACE_ETH_ALIAS: ${{ inputs.NAMADA_INTERFACE_ETH_ALIAS }}
NAMADA_INTERFACE_ETH_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_ETH_CHAIN_ID }}
NAMADA_INTERFACE_ETH_URL: ${{ inputs.NAMADA_INTERFACE_ETH_URL }}

- uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -249,25 +249,25 @@ jobs:

- name: Make release body text
run: |
echo "REACT_APP_NAMADA_ALIAS: $REACT_APP_NAMADA_ALIAS" >> RELEASE
echo "REACT_APP_NAMADA_CHAIN_ID: $REACT_APP_NAMADA_CHAIN_ID" >> RELEASE
echo "REACT_APP_NAMADA_URL: $REACT_APP_NAMADA_URL" >> RELEASE
echo "REACT_APP_COSMOS_ALIAS: $REACT_APP_COSMOS_ALIAS" >> RELEASE
echo "REACT_APP_COSMOS_CHAIN_ID: $REACT_APP_COSMOS_CHAIN_ID" >> RELEASE
echo "REACT_APP_COSMOS_URL: $REACT_APP_COSMOS_URL" >> RELEASE
echo "REACT_APP_ETH_ALIAS: $REACT_APP_ETH_ALIAS" >> RELEASE
echo "REACT_APP_ETH_CHAIN_ID: $REACT_APP_ETH_CHAIN_ID" >> RELEASE
echo "REACT_APP_ETH_URL: $REACT_APP_ETH_URL" >> RELEASE
echo "NAMADA_INTERFACE_NAMADA_ALIAS: $NAMADA_INTERFACE_NAMADA_ALIAS" >> RELEASE
echo "NAMADA_INTERFACE_NAMADA_CHAIN_ID: $NAMADA_INTERFACE_NAMADA_CHAIN_ID" >> RELEASE
echo "NAMADA_INTERFACE_NAMADA_URL: $NAMADA_INTERFACE_NAMADA_URL" >> RELEASE
echo "NAMADA_INTERFACE_COSMOS_ALIAS: $NAMADA_INTERFACE_COSMOS_ALIAS" >> RELEASE
echo "NAMADA_INTERFACE_COSMOS_CHAIN_ID: $NAMADA_INTERFACE_COSMOS_CHAIN_ID" >> RELEASE
echo "NAMADA_INTERFACE_COSMOS_URL: $NAMADA_INTERFACE_COSMOS_URL" >> RELEASE
echo "NAMADA_INTERFACE_ETH_ALIAS: $NAMADA_INTERFACE_ETH_ALIAS" >> RELEASE
echo "NAMADA_INTERFACE_ETH_CHAIN_ID: $NAMADA_INTERFACE_ETH_CHAIN_ID" >> RELEASE
echo "NAMADA_INTERFACE_ETH_URL: $NAMADA_INTERFACE_ETH_URL" >> RELEASE
env:
REACT_APP_NAMADA_ALIAS: ${{ inputs.REACT_APP_NAMADA_ALIAS }}
REACT_APP_NAMADA_CHAIN_ID: ${{ inputs.REACT_APP_NAMADA_CHAIN_ID }}
REACT_APP_NAMADA_URL: ${{ inputs.REACT_APP_NAMADA_URL }}
REACT_APP_COSMOS_ALIAS: ${{ inputs.REACT_APP_COSMOS_ALIAS }}
REACT_APP_COSMOS_CHAIN_ID: ${{ inputs.REACT_APP_COSMOS_CHAIN_ID }}
REACT_APP_COSMOS_URL: ${{ inputs.REACT_APP_COSMOS_URL }}
REACT_APP_ETH_ALIAS: ${{ inputs.REACT_APP_ETH_ALIAS }}
REACT_APP_ETH_CHAIN_ID: ${{ inputs.REACT_APP_ETH_CHAIN_ID }}
REACT_APP_ETH_URL: ${{ inputs.REACT_APP_ETH_URL }}
NAMADA_INTERFACE_NAMADA_ALIAS: ${{ inputs.NAMADA_INTERFACE_NAMADA_ALIAS }}
NAMADA_INTERFACE_NAMADA_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_NAMADA_CHAIN_ID }}
NAMADA_INTERFACE_NAMADA_URL: ${{ inputs.NAMADA_INTERFACE_NAMADA_URL }}
NAMADA_INTERFACE_COSMOS_ALIAS: ${{ inputs.NAMADA_INTERFACE_COSMOS_ALIAS }}
NAMADA_INTERFACE_COSMOS_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_COSMOS_CHAIN_ID }}
NAMADA_INTERFACE_COSMOS_URL: ${{ inputs.NAMADA_INTERFACE_COSMOS_URL }}
NAMADA_INTERFACE_ETH_ALIAS: ${{ inputs.NAMADA_INTERFACE_ETH_ALIAS }}
NAMADA_INTERFACE_ETH_CHAIN_ID: ${{ inputs.NAMADA_INTERFACE_ETH_CHAIN_ID }}
NAMADA_INTERFACE_ETH_URL: ${{ inputs.NAMADA_INTERFACE_ETH_URL }}

- name: Create release
id: create-release
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,8 @@ To build and run the chain locally, you will need to clone <http://github.com/an
with the actual chain ID from above):

```bash
REACT_APP_NAMADA_CHAIN_ID={CHAIN_ID}
REACT_APP_NAMADA_URL=http://127.0.0.1:27657/
NAMADA_INTERFACE_NAMADA_CHAIN_ID={CHAIN_ID}
NAMADA_INTERFACE_NAMADA_URL=http://127.0.0.1:27657/
```

### Extension
Expand Down
10 changes: 5 additions & 5 deletions apps/airdrop/.env.sample
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
REACT_APP_GITHUB_CLIENT_ID=Iv1.f2e59042dc8f21b9
REACT_APP_NAMADA_CHAIN_ID=qc-testnet-5.1.025a61165acd05e
REACT_APP_REDIRECT_URI=http://localhost:8081
AIRDROP_BACKEND_SERVICE_URL=http://localhost:5000
AIRDROP_AUTH_SECRET=header
NAMADA_INTERFACE_GITHUB_CLIENT_ID=Iv1.f2e59042dc8f21b9
NAMADA_INTERFACE_NAMADA_CHAIN_ID=qc-testnet-5.1.025a61165acd05e
NAMADA_INTERFACE_REDIRECT_URI=http://localhost:8081
NAMADA_INTERFACE_AIRDROP_BACKEND_SERVICE_URL=http://localhost:5000
NAMADA_INTERFACE_AIRDROP_AUTH_SECRET=header
6 changes: 3 additions & 3 deletions apps/airdrop/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ As an example, if all you want to override the API url and a GitHub app ID, you

```bash
# Faucet API Endpoint override
AIRDROP_BACKEND_SERVICE_URL=http://localhost:5000
NAMADA_INTERFACE_AIRDROP_BACKEND_SERVICE_URL=http://localhost:5000

# Github app ID override
REACT_APP_GITHUB_CLIENT_ID=Iv1.dbd15f7e1b50c0d7
NAMADA_INTERFACE_GITHUB_CLIENT_ID=Iv1.dbd15f7e1b50c0d7
```

Each token address used in this form may be overridden via values specified in `.env` (see [.env.sample](./.env.sample)).
Expand Down Expand Up @@ -54,7 +54,7 @@ you can launch the local CORS proxy via the following:
yarn dev:proxy
```

This will proxy the `AIRDROP_BACKEND_SERVICE_URL` (or default URL if this is unspecified) via a Node server, which should resolve the issue.
This will proxy the `NAMADA_INTERFACE_AIRDROP_BACKEND_SERVICE_URL` (or default URL if this is unspecified) via a Node server, which should resolve the issue.

[ [Table of Contents](#table-of-contents) ]

Expand Down
2 changes: 1 addition & 1 deletion apps/airdrop/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"start:proxy": "node ./scripts/startProxy.js",
"dev": "NODE_ENV=development && yarn start",
"dev:remote": "NODE_ENV=production && yarn start",
"dev:proxy": "REACT_APP_PROXY=true; ./scripts/start-proxy.sh; yarn dev",
"dev:proxy": "NAMADA_INTERFACE_PROXY=true; ./scripts/start-proxy.sh; yarn dev",
"build": "NODE_ENV=production && webpack-cli",
"lint": "npx eslint src --ext .ts,.tsx",
"lint:ci": "npx yarn lint --max-warnings 0",
Expand Down
4 changes: 2 additions & 2 deletions apps/airdrop/scripts/startProxies.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ const { exec } = require("child_process");
require("dotenv").config();

const {
AIRDROP_BACKEND_SERVICE_URL: apiUrl = "http://localhost:5000",
REACT_APP_PROXY_PORT: proxyPort = "9000",
NAMADA_INTERFACE_AIRDROP_BACKEND_SERVICE_URL: apiUrl = "http://localhost:5000",
NAMADA_INTERFACE_PROXY_PORT: proxyPort = "9000",
} = process.env;

const lcpCommand = `lcp --proxyUrl ${apiUrl} --port ${proxyPort}`;
Expand Down
4 changes: 2 additions & 2 deletions apps/airdrop/src/App/Buttons/GithubButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import { GithubIcon } from "App/Icons/GithubIcon";
import { ButtonProps } from "./types";

const {
REACT_APP_REDIRECT_URI: redirectUrl = "",
REACT_APP_GITHUB_CLIENT_ID: githubClientId = "",
NAMADA_INTERFACE_REDIRECT_URI: redirectUrl = "",
NAMADA_INTERFACE_GITHUB_CLIENT_ID: githubClientId = "",
} = process.env;

export const GithubButton = ({ disabled }: ButtonProps): JSX.Element => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ import {
TermsContainer,
} from "./ClaimConfirmation.components";

const { REACT_APP_NAMADA_CHAIN_ID: namadaChainId = "" } = process.env;
const { NAMADA_INTERFACE_NAMADA_CHAIN_ID: namadaChainId = "" } = process.env;

const claim = (
state: CommonState,
Expand Down
2 changes: 1 addition & 1 deletion apps/airdrop/src/App/claimService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
} from "./types";
import { AirdropResponse, airdropFetch } from "./utils";

const { AIRDROP_BACKEND_SERVICE_URL: backendUrl = "" } = process.env;
const { NAMADA_INTERFACE_AIRDROP_BACKEND_SERVICE_URL: backendUrl = "" } = process.env;

const AirdropApiPath = {
V1: `/api/v1/airdrop`,
Expand Down
4 changes: 2 additions & 2 deletions apps/airdrop/src/App/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ import { NavigateFunction } from "react-router-dom";
import { Label } from "./state";
import { MaybeOtherEVMWindow } from "./types";

const { NODE_ENV, AIRDROP_AUTH_SECRET = "header" } = process.env;
const { NODE_ENV, NAMADA_INTERFACE_AIRDROP_AUTH_SECRET = "header" } = process.env;
const AUTH_HEADER =
NODE_ENV === "development"
? // NODE_ENV === "production"
{ "x-airdrop-secret": AIRDROP_AUTH_SECRET }
{ "x-airdrop-secret": NAMADA_INTERFACE_AIRDROP_AUTH_SECRET }
: null;

export const navigatePostCheck = (
Expand Down
2 changes: 1 addition & 1 deletion apps/airdrop/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { IntegrationsContext } from "@namada/hooks";
import { Namada } from "@namada/integrations";
import namada from "@namada/chains/src/chains/namada";

const { REACT_APP_NAMADA_CHAIN_ID: namadaChainId = "namadaChainId" } =
const { NAMADA_INTERFACE_NAMADA_CHAIN_ID: namadaChainId = "namadaChainId" } =
process.env;

//We just use this for Namada
Expand Down
4 changes: 2 additions & 2 deletions apps/extension/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
"lint:ci": "yarn lint --max-warnings 0",
"start": "yarn start:chrome",
"start:chrome": "yarn clean:chrome && NODE_ENV=development TARGET=chrome webpack-cli --watch",
"start:chrome:proxy": "REACT_APP_PROXY=true yarn start:chrome",
"start:chrome:proxy": "NAMADA_INTERFACE_PROXY=true yarn start:chrome",
"start:firefox": "yarn clean:firefox && NODE_ENV=development TARGET=firefox webpack-cli --watch",
"start:firefox:proxy": "REACT_APP_PROXY=true yarn start:firefox",
"start:firefox:proxy": "NAMADA_INTERFACE_PROXY=true yarn start:firefox",
"test": "./scripts/build-node.sh && yarn jest",
"test:watch": "./scripts/build-node.sh && yarn jest --watchAll=true",
"test:ci": "jest",
Expand Down
2 changes: 1 addition & 1 deletion apps/extension/src/Approvals/ApproveTx/ConfirmTx.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import { closeCurrentTab } from "utils";
import { FetchAndStoreMaspParamsMsg, HasMaspParamsMsg } from "provider";
import { SubmitApprovedTxMsg } from "background/approvals";

const { REACT_APP_NAMADA_FAUCET_ADDRESS: faucetAddress } = process.env;
const { NAMADA_INTERFACE_NAMADA_FAUCET_ADDRESS: faucetAddress } = process.env;

type Props = {
details?: ApprovalDetails;
Expand Down
6 changes: 3 additions & 3 deletions apps/extension/src/background/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@ const txStore = new MemoryKVStore(KVPrefix.Memory);

const DEFAULT_URL =
"https://d3brk13lbhxfdb.cloudfront.net/qc-testnet-5.1.025a61165acd05e";
const { REACT_APP_PROXY, REACT_APP_NAMADA_URL = DEFAULT_URL } = process.env;
const { NAMADA_INTERFACE_PROXY, NAMADA_INTERFACE_NAMADA_URL = DEFAULT_URL } = process.env;

const NamadaRpcEndpoint = REACT_APP_PROXY
const NamadaRpcEndpoint = NAMADA_INTERFACE_PROXY
? ProxyMappings["namada"]
: REACT_APP_NAMADA_URL;
: NAMADA_INTERFACE_NAMADA_URL;

const messenger = new ExtensionMessenger();
const router = new ExtensionRouter(
Expand Down
Loading

0 comments on commit 570f068

Please sign in to comment.