Skip to main content

Server & runtime

Settings for the Norish server. Most have working defaults, but you must provide your own MASTER_KEY.

Core

VariableDescriptionDefault
MASTER_KEY32+ character key for encryption derivation(required)
AUTH_URLPublic URL used for auth callbacks and linkshttp://localhost:3000
NODE_ENVRuntime environmentproduction (set by the Docker image)
HOSTServer bind address0.0.0.0
PORTServer port3000
REDIS_URLRedis connection URL for events and jobsredis://localhost:6379

Generate a MASTER_KEY

Norish derives the keys that encrypt stored secrets from MASTER_KEY, so changing it makes them unreadable. Generate one with:

openssl rand -base64 32

Networking & origins

VariableDescriptionDefault
TRUSTED_ORIGINSComma-separated additional trusted origins(empty)

Set TRUSTED_ORIGINS when people reach Norish on more than one address, for example http://192.168.1.100:3000,https://norish.example.com. The WebSocket refuses origins it doesn't trust, see Origin check.

Auth rate limiting

VariableDescriptionDefault
AUTH_RATE_LIMIT_ENABLEDEnable auth endpoint rate limitingtrue
AUTH_RATE_LIMIT_WINDOWWindow length in seconds60
AUTH_RATE_LIMIT_MAXRequests allowed per window20

Warning

Turning this off removes brute-force protection from sign-in.

Registration

VariableDescriptionDefault
ENABLE_REGISTRATIONAllow new-user registrationfalse

Registration turns off after the first user signs in, see Authentication.

Logging

VariableDescriptionDefault
NEXT_PUBLIC_LOG_LEVELLog verbosity (debug, info, warn, error)info

Uploads

VariableDescriptionDefault
UPLOADS_DIRUpload storage directory./.runtime/uploads (dev), /app/uploads (prod)
MAX_AVATAR_FILE_SIZEMax avatar upload size (bytes)5242880
MAX_IMAGE_FILE_SIZEMax image upload size (bytes)10485760
MAX_VIDEO_FILE_SIZEMax video upload size (bytes)104857600

Scheduler

VariableDescriptionDefault
SCHEDULER_CLEANUP_MONTHSCleanup retention period in months3

Ingredient catalogue

VariableDescriptionDefault
INGREDIENT_CATALOGUE_URLWhere the ingredient catalogue seed is fetched from, nightly and at startup. Empty turns the fetch offThe Open Food Facts ingredients taxonomy
INGREDIENT_REVIEW_CONCURRENCYHow many ingredients are asked at once, from 1 to 50. Lower it when a self-hosted model struggles with parallel requests10

Norish seeds its ingredient catalogue from the Open Food Facts ingredients taxonomy and refreshes it every night at midnight.

On a server without internet, serve a copy of ingredients.txt from a local mirror and point INGREDIENT_CATALOGUE_URL at it, or leave it empty. Norish works either way.

The taxonomy is under the Open Database License (ODbL). Download it under Settings => Ingredients => Data sources.