Skip to content

Configuration

Teddy Paul edited this page Dec 7, 2022 · 9 revisions

Each service has its own JavaScript configuration files. Default configuration can be overridden in 2 ways:

  • providing a local.js file in service config folder. Settings specified in this file will override default ones. More info here
  • setting environment variables at runtime.

Core

Config folder: apps/core/config

Available settings:

All mandatory settings have no default value and must be provided

Env variable Description Default value Mandatory
SERVER_HOST Server host localhost
SERVER_PORT Server port 4001
SERVER_PUBLIC_URL Public URL http://localhost:4001
SERVER_WS_URL Websocket URL http://localhost:4001
API_ENDPOINT GraphlQL API endpoint graphql
SERVER_ALLOW_INTROSPECTION Allow GraphQL introspection queries true
SERVER_UPLOAD_LIMIT Upload limit 100mb
SERVER_SUPPORT_EMAIL Email shown in "contact support" links *
SERVER_ADMIN_LOGIN Admin default login *
SERVER_ADMIN_PASSWORD Admin default password *
SERVER_ADMIN_EMAIL Admin default email *
SERVER_SYSTEM_USER_EMAIL System user default email system@leav-engine.com
ARANGO_URL ArangoDB URL, including username and password *
DB_NAME Database name leav_core
DISK_CACHE_DIRECTORY Directory where disk cache will be stored /cache
ELASTICSEARCH_URL Elastic Search URL http://elasticsearch:9200
AUTH_KEY Key used to generate authentication token *
TOKEN_TTL Authentication token Time To Live 7d
AUTH_COOKIE_SAMESITE samesite settings for authentication cookies lax
AUTH_COOKIE_SECURE secure flag for authentication cookies false
AUTH_RESET_PWD_TTL "Reset password" time to live 20m
MAILER_HOST Host of server for sending emails localhost
MAILER_PORT Port of server for sending emails 587
MAILER_SECURE Use secure connection for sending emails false
MAILER_AUTH_USER Emails server username *
MAILER_AUTH_PWD Emails server password *
LANG_AVAILABLE Available languages ['fr', 'en']
LANG_DEFAULT Default language fr
LOG_LEVEL Log level (More info info
LOG_TRANSPORT Log transport (Comma separated list of transport, including : console, file) console,file
LOG_FILE Log destination file * (if transport includes "file")
AMQP_HOST Host of RabbitMQ server *
AMQP_USERNAME Username of RabbitMQ server *
AMQP_PWD Password of RabbitMQ server *
AMQP_PORT Port of RabbitMQ server 5672
AMQP_EXCHANGE Exchange name where RabbitMQ messages are sent leav_core
AMQP_TYPE Type of exchange for messages routin (more info direct
AMQP_PREFETCH Number of messages fetched simultaneously 5
REDIS_HOST
REDIS_PORT
REDIS_DATABASE
FM_EVENTS_QUEUE
FM_PREVIEW_REQUEST_QUEUE
FM_PREVIEW_RESPONSE_QUEUE
FM_USER_ID
FM_USER_GROUPS_IDS
TM_NB_WORKERS
TM_ORDERS_QUEUE
DEBUG
EXPORT_DIR
IMPORT_DIR
IMPORT_SIZE_LIMIT
IMPORT_GROUP_DATA
PREVIEWS_DIRECTORY
APPLICATIONS_FOLDER
FILES_ROOT_PATHS
FILES_ORIGINALS_PREFIX
DB_PROFILER_ENABLE
DB_PROFILER_ENABLE
Clone this wiki locally