diff --git a/.env.example b/.env.example deleted file mode 100755 index 9bdf233..0000000 --- a/.env.example +++ /dev/null @@ -1,17 +0,0 @@ -# Since the ".env" file is gitignored, you can use the ".env.example" file to -# build a new ".env" file when you clone the repo. Keep this file up-to-date -# when you add new variables to `.env`. - -# This file will be committed to version control, so make sure not to have any -# secrets in it. If you are cloning this repo, create a copy of this file named -# ".env" and populate it with your secrets. - -# When adding additional environment variables, the schema in "/src/env.js" -# should be updated accordingly. - -# Drizzle -DATABASE_URL="postgresql://postgres:password@localhost:5432/wavelength_server" - -# Example: -# SERVERVAR="foo" -# NEXT_PUBLIC_CLIENTVAR="bar" diff --git a/websocket_server/src/server.ts b/websocket_server/src/server.ts index 789f74f..9f891eb 100644 --- a/websocket_server/src/server.ts +++ b/websocket_server/src/server.ts @@ -1,7 +1,8 @@ import express from 'express'; import { Server } from 'socket.io'; import { createServer } from 'http'; -import { Client, Notification } from 'pg'; +import { Client } from 'pg'; +import type { Notification } from 'pg'; import dotenv from 'dotenv'; dotenv.config(); @@ -11,7 +12,7 @@ const httpServer = createServer(app); // Create new Socket.IO server const io = new Server(httpServer); -const PORT = process.env.PORT || 3030; +const PORT = process.env.PORT ?? 3020; const pgClient = new Client({ connectionString: process.env.DATABASE_URL,