diff --git a/README.md b/README.md index cbe2db0..99f04c8 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,8 @@ | POSTGRES_PASSWORD `REQUIRED` | `null` | `postgres` | Password that will be used in postgres database | | POSTGRES_IP `REQUIRED` | `null` | `jellystat-db` or `192.168.0.5` | Hostname/IP of postgres instance | | POSTGRES_PORT `REQUIRED` | `null` | `5432` | Port Postgres is running on | -| JS_LISTEN_IP | `0.0.0.0`| `0.0.0.0` or `::` | Enable listening on specific IP or `::` for IPv6 | +| JS_LISTEN_IP | `0.0.0.0`| `0.0.0.0` or `::` | Enable listening on specific IP or `::` for IPv6 | +| JS_PORT | `3000` | `3001` | Port | | JWT_SECRET `REQUIRED` | `null` | `my-secret-jwt-key` | JWT Key to be used to encrypt JWT tokens for authentication | | TZ `REQUIRED` | `null` | `Etc/UTC` | Server timezone (Can be found at https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) | | JS_BASE_URL | `/` | `/` | Base url | @@ -38,11 +39,12 @@ | JS_PASSWORD | `null` | `Password` | Master Override Password in case username or password used during setup is forgotten (Both `JS_USER` and `JS_PASSWORD` required to work) | | POSTGRES_DB | `jfstat` | `jfstat` | Name of postgres database | | REJECT_SELF_SIGNED_CERTIFICATES | `true` | `false` | Allow or deny self signed SSL certificates | -| JS_GEOLITE_ACCOUNT_ID | `null` | `123456` | maxmind.com user id to be used for Geolocating IP Addresses (Can be found at https://www.maxmind.com/en/accounts/current/edit) | +| JS_GEOLITE_ACCOUNT_ID | `null` | `123456` | maxmind.com user id to be used for Geolocating IP Addresses (Can be found at https://www.maxmind.com/en/accounts/current/edit) | | JS_GEOLITE_LICENSE_KEY | `null` | `ASDWdaSdawe2sd186` | License key you need to generate on maxmind to use their services | | MINIMUM_SECONDS_TO_INCLUDE_PLAYBACK | `1` | `10` | The minimum time (in seconds) to include a playback record, which can be used to exclude short playbacks | | IS_EMBY_API | `false` | `true` | Set to true if using Emby instead of Jellyfin | + ## Getting Started with Development - Clone the project from git diff --git a/backend/.env.example b/backend/.env.example index bd4efdb..a490f20 100644 --- a/backend/.env.example +++ b/backend/.env.example @@ -7,4 +7,7 @@ POSTGRES_PORT = # your postgres port JWT_SECRET = # ultra secret word JS_GEOLITE_ACCOUNT_ID = # optional, your GeoLite account ID to show geolocation info for client IPs -JS_GEOLITE_LICENSE_KEY = # optional, your GeoLite account license key to show geolocation info for client IPs \ No newline at end of file +JS_GEOLITE_LICENSE_KEY = # optional, your GeoLite account license key to show geolocation info for client IPs + +JS_LISTEN_IP = # your bind address +JS_PORT = # your jellystat port diff --git a/backend/server.js b/backend/server.js index 8d4b82a..699646c 100644 --- a/backend/server.js +++ b/backend/server.js @@ -52,8 +52,9 @@ const ensureSlashes = (url) => { return url; }; -const PORT = 3000; -const LISTEN_IP = process.env.JS_LISTEN_IP || "0.0.0.0"; + +const JS_PORT = process.env.JS_PORT || 3000; +const JS_LISTEN_IP = process.env.JS_LISTEN_IP || "0.0.0.0"; const JWT_SECRET = process.env.JWT_SECRET; const BASE_NAME = process.env.JS_BASE_URL ? ensureSlashes(process.env.JS_BASE_URL) : "";