Skip to content

Commit

Permalink
Support port customization
Browse files Browse the repository at this point in the history
  • Loading branch information
Inkvi committed May 10, 2024
1 parent 9560e47 commit f851ec6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,9 @@ async function handleEthSignTransaction(transactionArgs: TransactionArgs) {

const start = async () => {
try {
await app.listen({port: 8000});
console.log('Server running at https://localhost:8000/');
let port = parseInt(process.env.PORT ?? "8000");
await app.listen({port: port});
console.log(`Server running at https://localhost:${port}/`);
} catch (err) {
console.error(err);
process.exit(1);
Expand Down

0 comments on commit f851ec6

Please sign in to comment.