Default Environment Variable

Plumier facilities automatically check into some environment variable name during initialization, this process is optional because you still can configure the facility manually on your code.

For example, the JwtAuthFacility if registered without parameter it will check to the PLUM_JWT_SECRET environment variable.

new Plumier()
// automatically check for PLUM_JWT_SECRET for JWT secret
.set(new JwtAuthFacility())

Or you can configure the facility manually from your code like below

new Plumier()
.set(new JwtAuthFacility({ secret: process.env.YOUR_JWT_SECRET }))
Env VariableFacilityDescription
PLUM_FORCE_HTTPSWebApiFacilitySet force https, enable trustProxyHeader configuration separately
PLUM_JWT_SECRETJwtAuthFacilityStore JWT secret
PLUM_MONGODB_URIMongooseFacilityStore MongoDB uri
PLUM_FACEBOOK_CLIENT_IDFacebookOAuthFacilityStore Facebook OAuth 2.0 client id
PLUM_FACEBOOK_CLIENT_SECRETFacebookOAuthFacilityStore Facebook OAuth 2.0 client secret
PLUM_GOOGLE_CLIENT_IDGoogleOAuthFacilityStore Google OAuth 2.0 client id
PLUM_GOOGLE_CLIENT_CLIENT_SECRETGoogleOAuthFacilityStore Google OAuth 2.0 client secret
PLUM_GITHUB_CLIENT_IDGithubOAuthFacilityStore Github OAuth 2.0 client id
PLUM_GITHUB_CLIENT_CLIENT_SECRETGithubOAuthFacilityStore Github OAuth 2.0 client secret
PLUM_GITLAB_CLIENT_IDGitLabOAuthFacilityStore GitLab OAuth 2.0 client id
PLUM_GITLAB_CLIENT_CLIENT_SECRETGitLabOAuthFacilityStore GitLab OAuth 2.0 client secret
PLUM_TWITTER_CLIENT_IDTwitterOAuthFacilityStore Twitter OAuth 1.0a client id
PLUM_TWITTER_CLIENT_CLIENT_SECRETTwitterOAuthFacilityStore Twitter OAuth 1.0a client secret