Skip to content

Commit

Permalink
chore: github env vars
Browse files Browse the repository at this point in the history
  • Loading branch information
veryCrunchy committed Apr 2, 2024
1 parent 6187229 commit 852f140
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ CALLBACK_URL="https://beta.greasygang.co/auth/callback"
DB_NAME=""

#ENV_VARS
BASE_URL="http://localhost:4000"
CALLBACK_URL="http://localhost:3000/auth/callback"
DB_NAME=""

DB_HOST="localhost"
DB_USER=""
DB_PASS=""
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "",
"main": "index.js",
"scripts": {
"dev": "cross-env NODE_ENV=development tsx watch src/main.ts --host 127.0.0.1",
"dev": "cross-env NODE_ENV=development tsx watch src/main.ts",
"start": "tsx src/main.ts",
"generate": "drizzle-kit generate:mysql",
"pull": "drizzle-kit introspect:mysql",
Expand Down
6 changes: 4 additions & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ try {
"JWT_SECRET",
"CALLBACK_URL",
"BASE_URL",
"GITHUB_TOKEN",
"GITHUB_OWNER",
"GITHUB_REPO",
"TWITCH_CLIENT_ID",
"TWITCH_CLIENT_SECRET",
"DISCORD_CLIENT_ID",
Expand Down Expand Up @@ -105,8 +108,7 @@ app.get("/image/:imagePath(*)", async (req, res) => {
res.setHeader("Content-Type", "image/png");
res.send(data);
} catch (error) {
console.error("Error fetching image:", error);
res.status(500).send("Internal Server Error");
res.status(404);
}
});

Expand Down

0 comments on commit 852f140

Please sign in to comment.