From 4921cd7ecbb937b3197027635b6a2a1c7c43db69 Mon Sep 17 00:00:00 2001 From: Benny Joo Date: Tue, 24 Sep 2024 12:32:43 -0400 Subject: [PATCH] add env vars (#16791) --- .env.example | 2 ++ apps/web/abTest/middlewareFactory.ts | 2 ++ apps/web/scripts/vercel-app-router-deploy.sh | 2 ++ turbo.json | 2 ++ 4 files changed, 8 insertions(+) diff --git a/.env.example b/.env.example index ff2e2c1875f4a0..14c3410bb93970 100644 --- a/.env.example +++ b/.env.example @@ -333,6 +333,8 @@ E2E_TEST_OIDC_USER_PASSWORD= AB_TEST_BUCKET_PROBABILITY=50 # whether we redirect to the future/event-types from event-types or not APP_ROUTER_EVENT_TYPES_ENABLED=0 +APP_ROUTER_SETTINGS_DEVELOPER_ENABLED=0 +APP_ROUTER_SETTINGS_SECURITY_ENABLED=0 APP_ROUTER_SETTINGS_ADMIN_ENABLED=0 APP_ROUTER_SETTINGS_PLATFORM_ENABLED=0 APP_ROUTER_SETTINGS_ORG_ENABLED=0 diff --git a/apps/web/abTest/middlewareFactory.ts b/apps/web/abTest/middlewareFactory.ts index c04f08fd15297e..119c81d053ad17 100644 --- a/apps/web/abTest/middlewareFactory.ts +++ b/apps/web/abTest/middlewareFactory.ts @@ -7,6 +7,8 @@ import { FUTURE_ROUTES_ENABLED_COOKIE_NAME, FUTURE_ROUTES_OVERRIDE_COOKIE_NAME } const ROUTES: [URLPattern, boolean][] = [ ["/event-types", process.env.APP_ROUTER_EVENT_TYPES_ENABLED === "1"] as const, + ["/settings/developer/:path*", process.env.APP_ROUTER_SETTINGS_DEVELOPER_ENABLED === "1"] as const, + ["/settings/security/:path*", process.env.APP_ROUTER_SETTINGS_SECURITY_ENABLED === "1"] as const, ["/settings/admin/:path*", process.env.APP_ROUTER_SETTINGS_ADMIN_ENABLED === "1"] as const, ["/settings/platform/:path*", process.env.APP_ROUTER_SETTINGS_PLATFORM_ENABLED === "1"] as const, ["/settings/organizations/:path*", process.env.APP_ROUTER_SETTINGS_ORG_ENABLED === "1"] as const, diff --git a/apps/web/scripts/vercel-app-router-deploy.sh b/apps/web/scripts/vercel-app-router-deploy.sh index 1d44f26cdc5204..75b7f282b5c71d 100755 --- a/apps/web/scripts/vercel-app-router-deploy.sh +++ b/apps/web/scripts/vercel-app-router-deploy.sh @@ -8,6 +8,8 @@ checkRoute () { # This is to reduce the size of the build and prevent OOM errors checkRoute "$APP_ROUTER_EVENT_TYPES_ENABLED" app/future/event-types checkRoute "$APP_ROUTER_AVAILABILITY_ENABLED" app/future/availability +checkRoute "$APP_ROUTER_SETTINGS_DEVELOPER_ENABLED" app/future/settings/developer +checkRoute "$APP_ROUTER_SETTINGS_SECURITY_ENABLED" app/future/settings/security checkRoute "$APP_ROUTER_SETTINGS_ADMIN_ENABLED" app/future/settings/admin checkRoute "$APP_ROUTER_SETTINGS_PLATFORM_ENABLED" app/future/settings/platform checkRoute "$APP_ROUTER_SETTINGS_ORG_ENABLED" app/future/settings/organizations diff --git a/turbo.json b/turbo.json index 3091f2940adf29..8fcc1c12ce800c 100644 --- a/turbo.json +++ b/turbo.json @@ -236,6 +236,8 @@ "APP_ROUTER_BOOKINGS_STATUS_ENABLED", "APP_ROUTER_EVENT_TYPES_ENABLED", "APP_ROUTER_GETTING_STARTED_STEP_ENABLED", + "APP_ROUTER_SETTINGS_DEVELOPER_ENABLED", + "APP_ROUTER_SETTINGS_SECURITY_ENABLED", "APP_ROUTER_SETTINGS_ADMIN_ENABLED", "APP_ROUTER_SETTINGS_PLATFORM_ENABLED", "APP_ROUTER_SETTINGS_ORG_ENABLED",