Skip to content

Commit

Permalink
Add host env variable
Browse files Browse the repository at this point in the history
  • Loading branch information
nas5w committed Jan 12, 2025
1 parent 7c00270 commit 019265c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion projects/api/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ async function setupServer() {
reply.send({ handles });
});

fastify.listen({ port }, (err) => {
fastify.listen({ port, host: process.env.HOST || "localhost" }, (err) => {
if (err) throw err;
console.log(`Fastify server listening at http://localhost:${port}`);
});
Expand Down

0 comments on commit 019265c

Please sign in to comment.