Skip to content

Commit

Permalink
change the env schema
Browse files Browse the repository at this point in the history
  • Loading branch information
KatyH820 committed Apr 29, 2024
1 parent 72c27cd commit 02664c0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Deploy main branch development
on:
push:
branches:
- main
- main, deploy

jobs:
deploy:
Expand Down
4 changes: 3 additions & 1 deletion apps/server/src/functions/env.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ import { z } from "zod";
dotenv.config({
path: "../../../../.env",
});

const envSchema = z.object({
DATABASE_URL: z.string(),
AWS_ACCESS_KEY_ID: z.string(),
AWS_SECRET_ACCESS_KEY: z.string(),
});

const env = envSchema.parse(process.env);
export { env };

0 comments on commit 02664c0

Please sign in to comment.