Environment Variables
Any configuration in the API must be driven by environment variables.
NODE_ENV
: Defines which environment the services will be running against.- Default: local
- Options: local, development, qa, staging, prod
LOG
: Log level to be displayed.- Default: INFO
- Options: ERROR, INFO, DEBUG, LOG.
PORT
: Defines the port the gateway service will listen.- Default: 8000
PUPPETEER_EXECUTABLE_PATH
:- Cross-Service Communication:
CP_HOST
: Defines the host the Client Portal service will listen.- Default: localhost
CP_PORT
: Defines the port the Client Portal service will listen.- Default: 8100
MAIL_HOST
: Defines the host the mail service will listen.- Default: localhost
MAIL_PORT
: Defines the port the mail service will listen.- Default: 8200
PDF_HOST
: Defines the host the pdf service will listen.- Default: localhost
PDF_PORT
: Defines the port the pdf service will listen.- Default: 8300
TP_HOST
: Defines the host the Titan Portal service will listen.- Default: localhost
TP_PORT
: Defines the port the Titan Portal service will listen.- Default: 8400
SEARCH_HOST
: Defines the host the Search service will listen.- Default: localhost
SEARCH_PORT
: Defines the port the Search service will listen.- Default: 8500
TOKEN_HOST
: Defines the host the Token service will listen.- Default: localhost
TOKEN_PORT
: Defines the port the Token service will listen.- Default: 9100
- PM2 Credentials:
These credentials are not being used in our code, but rather in the serve pm2 script (ran only in ESB)
PM2_PUBLIC_KEY
:PM2_SECRET_KEY
:
- JWT Configuration:
JWT_SECRET
:JWT_REFRESH_SECRET
:JWT_LIFETIME_SEC
:- Default: 300 5 minutes
JWT_REFRESH_LIFETIME_SEC
:- Default: 604800 7 days
- RDS Database Configuration:
RDS_HOST
: Postgres endpointRDS_PORT
: Postgres port- Default: 5432
RDS_USER
: User to be used to authenticate in Postgres databaseRDS_PASS
: Password to be used to authenticate in Postgres database
- Elasticsearch Configuration:
ES_HOST
: Elasticsearch cluster endpointES_PORT
: Elasticsearch port- Default: 5432
- Redis Configuration:
REDIS_HOST
: Redis endpointREDIS_PORT
: Redis port- Default: 6379
- Mailgun Credentials:
MAILGUN_API_KEY
: API Key provided by Mailgun accountMAILGUN_DOMAIN
: Titanhouse domain to use to send/receive e-mails
- Sentry Configuration:
SENTRY_DSN
: Sentry credential to log errors
- AWS Configuration:
AWS_REGION
: Amazon region the service is running atEFS_ID
:EFS_MOUNT
:
- Titan Portal Configuration:
COOKIE_SECRET
:EMAIL_CONFIRMATION_SECRET
:PASSWORD_RESET_SALT
:TP_PORTAL_TOKEN
:SUPPORT_HELP_EMAILS
:- Database:
TP_RDS_DB_NAME
: Defines which database the Titan Portal app will use
- Linkedin Credentials:
LINKEDIN_APP_ID
:LINKEDIN_APP_SECRET
:
- AWS Configuration:
TP_S3_BUCKET_NAME
TP_AWS_SECRET_KEY
:TP_AWS_ACCESS_KEY
:
- Research Tool Credentials:
RESEARCH_SERVER_HOST
: Research Tool API hostnameRESEARCH_SERVER_USERNAME
: User to authenticate in Research Tool APIRESEARCH_SERVER_PASSWORD
: Password to authenticate in Research Tool API
- Client Portal:
CLIENT_PORTAL_API_HOST
: Client Portal API hostnameCLIENT_PORTAL_MAIL_PATH
: Path for the message endpoint in Client Portal APICLIENT_PORTAL_LOGIN
: User to authenticate in Client Portal APICLIENT_PORTAL_PASSWORD
: Password to authenticate in Client Portal API
- Client Portal Configuration:
CP_PORTAL_ORIGIN
: Defines the url Client Portal UI is using- Database:
CP_RDS_DB_NAME
: Defines which database the Client Portal app will use
- AWS Configuration:
Specify AWS credentials to be use in order to use its services
AWS_ACCESS_KEY_ID
:AWS_SECRET_KEY
: