diff --git a/apps/app/README.md b/apps/app/README.md index 3a540ef6c..d7cc2f575 100644 --- a/apps/app/README.md +++ b/apps/app/README.md @@ -46,6 +46,7 @@ Configure the nearblocks Gateway by modifying the .env file. Customize settings `BREVO_API_KEY=` `BREVO_TO_EMAIL=` `NEXT_PUBLIC_GTM_ID=GTM-P285ZPV2` +`API_KEY=` ## Deployment diff --git a/apps/app/src/pages/hash/[receipt].tsx b/apps/app/src/pages/hash/[receipt].tsx index 9312ef3e7..9c828ec1c 100644 --- a/apps/app/src/pages/hash/[receipt].tsx +++ b/apps/app/src/pages/hash/[receipt].tsx @@ -25,6 +25,7 @@ export const getServerSideProps = async (context: any) => { method: 'GET', headers: { 'Content-Type': 'application/json', + Authorization: `Bearer ${process.env.API_KEY}`, }, }, ); diff --git a/mainnet-app.yml b/mainnet-app.yml index b2063c7b6..0a27bd2a7 100644 --- a/mainnet-app.yml +++ b/mainnet-app.yml @@ -19,3 +19,4 @@ services: BREVO_API_KEY: ${BREVO_API_KEY} BREVO_TO_EMAIL: ${BREVO_TO_EMAIL} NEXT_PUBLIC_GTM_ID: GTM-P285ZPV2 + env_file: testnet.app.env diff --git a/mainnet.app.env.example b/mainnet.app.env.example new file mode 100644 index 000000000..48204cddd --- /dev/null +++ b/mainnet.app.env.example @@ -0,0 +1 @@ +API_KEY= diff --git a/testnet-app.yml b/testnet-app.yml index 158fb38af..be3be27f0 100644 --- a/testnet-app.yml +++ b/testnet-app.yml @@ -19,3 +19,4 @@ services: BREVO_API_KEY: ${BREVO_API_KEY} BREVO_TO_EMAIL: ${BREVO_TO_EMAIL} NEXT_PUBLIC_GTM_ID: GTM-P285ZPV2 + env_file: testnet.app.env diff --git a/testnet.app.env.example b/testnet.app.env.example new file mode 100644 index 000000000..48204cddd --- /dev/null +++ b/testnet.app.env.example @@ -0,0 +1 @@ +API_KEY= diff --git a/turbo.json b/turbo.json index ad51c98d7..14f10042f 100644 --- a/turbo.json +++ b/turbo.json @@ -1,7 +1,7 @@ { "$schema": "https://turbo.build/schema.json", "globalDependencies": ["**/.env.*local"], - "globalEnv": ["PORT"], + "globalEnv": ["PORT", "API_KEY"], "pipeline": { "build": { "outputs": ["dist/**", ".next/**", "!.next/cache/**", "public/dist/**"],