Skip to content

Commit 91caf12

Browse files
chore: add default PostHog token in env.server.ts for development scenarios
1 parent 9257888 commit 91caf12

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,7 @@ ENV SOURCEBOT_PUBLIC_KEY_PATH=/app/public.pem
174174
# Note that this key does not need to be kept secret, so it's not
175175
# necessary to use Docker build secrets here.
176176
# @see: https://posthog.com/tutorials/api-capture-events#authenticating-with-the-project-api-key
177+
# @note: this is also declared in the shared env.server.ts file.
177178
ENV POSTHOG_PAPIK=phc_lLPuFFi5LH6c94eFJcqvYVFwiJffVcV6HD8U4a1OnRW
178179

179180
# Valid values are: debug, info, warn, error

packages/shared/src/env.server.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,8 @@ export const env = createEnv({
120120
CONFIG_MAX_REPOS_NO_TOKEN: numberSchema.default(Number.MAX_SAFE_INTEGER),
121121
NODE_ENV: z.enum(["development", "test", "production"]),
122122
SOURCEBOT_TELEMETRY_DISABLED: booleanSchema.default('false'),
123-
POSTHOG_PAPIK: z.string(),
123+
// @note: this is also declared in the Dockerfile.
124+
POSTHOG_PAPIK: z.string().default("phc_lLPuFFi5LH6c94eFJcqvYVFwiJffVcV6HD8U4a1OnRW"),
124125

125126
// Database variables
126127
// Either DATABASE_URL or DATABASE_HOST, DATABASE_USERNAME, DATABASE_PASSWORD, and DATABASE_NAME must be set.

0 commit comments

Comments
 (0)