Skip to content

Commit

Permalink
fix: made postgres optional
Browse files Browse the repository at this point in the history
  • Loading branch information
nolostra committed Sep 20, 2024
1 parent 01b27aa commit a352264
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/env/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ export const serverEnv = createEnv({
DATABASE_URL: z.string().url(),
NEXTAUTH_SECRET: z.string().min(1),
NEXTAUTH_URL: z.string().url(),
POSTGRES_URL: z.string().url(),
POSTGRES_HOST: z.string().min(1),
POSTGRES_USERNAME: z.string().min(1),
POSTGRES_PASSWORD: z.string().min(1),
POSTGRES_URL: z.string().url().optional(),
POSTGRES_HOST: z.string().min(1).optional(),
POSTGRES_USERNAME: z.string().min(1).optional(),
POSTGRES_PASSWORD: z.string().min(1).optional(),
AWS_S3_REGION: z.string().min(1),
AWS_S3_ACCESS_KEY_ID: z.string().min(1),
AWS_S3_SECRET_ACCESS_KEY: z.string().min(1),
Expand All @@ -23,10 +23,10 @@ export const serverEnv = createEnv({
DATABASE_URL: process.env.DATABASE_URL,
NEXTAUTH_SECRET: process.env.NEXTAUTH_SECRET,
NEXTAUTH_URL: process.env.NEXTAUTH_URL,
POSTGRES_URL: process.env.POSTGRES_URL,
POSTGRES_HOST: process.env.POSTGRES_HOST,
POSTGRES_USERNAME: process.env.POSTGRES_USERNAME,
POSTGRES_PASSWORD: process.env.POSTGRES_PASSWORD,
POSTGRES_URL: process.env.POSTGRES_URL ?? '',
POSTGRES_HOST: process.env.POSTGRES_HOST ?? '',
POSTGRES_USERNAME: process.env.POSTGRES_USERNAME ?? '',
POSTGRES_PASSWORD: process.env.POSTGRES_PASSWORD ?? '',
AWS_S3_REGION: process.env.AWS_S3_REGION,
AWS_S3_ACCESS_KEY_ID: process.env.AWS_S3_ACCESS_KEY_ID,
AWS_S3_SECRET_ACCESS_KEY: process.env.AWS_S3_SECRET_ACCESS_KEY,
Expand Down

0 comments on commit a352264

Please sign in to comment.