diff --git a/src/nextapp/.env.local b/src/nextapp/.env.local index 4fdcfcabd..eb58974e5 100644 --- a/src/nextapp/.env.local +++ b/src/nextapp/.env.local @@ -1,5 +1,6 @@ NEXT_PUBLIC_APP_VERSION=0.0.0 NEXT_PUBLIC_APP_REVISION=000000000000000000000000 +NEXT_PUBLIC_API_ROOT=http://oauth2proxy.localtest.me:4180/ NEXT_PUBLIC_GRAFANA_URL=https://grafana-apps-gov-bc-ca.dev.api.gov.bc.ca NEXT_PUBLIC_KUBE_CLUSTER=local NEXT_PUBLIC_HELP_DESK_URL=https://dpdd.atlassian.net/servicedesk/customer/portal/1/group/2 @@ -9,4 +10,3 @@ NEXT_PUBLIC_HELP_API_DOCS_URL=/ds/api/v3/console/ NEXT_PUBLIC_HELP_SUPPORT_URL=https://dev.developer.gov.bc.ca/docs/default/component/aps-infra-platform-docs/ NEXT_PUBLIC_HELP_RELEASE_URL=https://dev.developer.gov.bc.ca/docs/default/component/aps-infra-platform-docs/reference/releases/ NEXT_PUBLIC_HELP_STATUS_URL=https://uptime.com/s/bcgov-dss - diff --git a/src/nextapp/components/gateway-get-started/gateway-get-started.tsx b/src/nextapp/components/gateway-get-started/gateway-get-started.tsx index b3016bb3b..409bb4cd4 100644 --- a/src/nextapp/components/gateway-get-started/gateway-get-started.tsx +++ b/src/nextapp/components/gateway-get-started/gateway-get-started.tsx @@ -50,6 +50,8 @@ const GatewayGetStarted: React.FC = () => { const QuickStartUrl = global?.helpLinks.helpSupportUrl + 'tutorials/quick-start' const GwaInstallUrl = global?.helpLinks.helpSupportUrl + 'how-to/gwa-install' const GwaCommandsUrl = global?.helpLinks.helpSupportUrl + 'resources/gwa-commands' + const apiRootUrl = global?.apiRootUrl + const configHost = apiRootUrl ? apiRootUrl.replace('https://', '').replace('http://', '') : '' return ( <> @@ -304,11 +306,13 @@ const GatewayGetStarted: React.FC = () => { Prepare your configuration - + {global?.apiRootUrl && ( + + )} ; readonly helpLinks: Record; readonly identities: { @@ -18,6 +19,7 @@ const defaultState = { version: '', revision: '', cluster: '', + apiRootUrl: '', identities: { developer: ['idir'], provider: ['idir'], diff --git a/src/server.ts b/src/server.ts index c03dcef7a..f1aff5d28 100644 --- a/src/server.ts +++ b/src/server.ts @@ -384,6 +384,7 @@ const configureExpress = (app: any) => { version: process.env.NEXT_PUBLIC_APP_VERSION, revision: process.env.NEXT_PUBLIC_APP_REVISION, cluster: process.env.NEXT_PUBLIC_KUBE_CLUSTER, + apiRootUrl: process.env.NEXT_PUBLIC_API_ROOT, identities: { developer: (process.env.NEXT_PUBLIC_DEVELOPER_IDS || '').split(','), provider: (process.env.NEXT_PUBLIC_PROVIDER_IDS || '').split(','),