Skip to main content

Environment Variables Reference

Complete reference for CMP .env configuration variables. Copy .env.example as a starting point and fill in values for your environment.

Application​

VariableDescriptionExample
APP_NAMEDisplay name for the applicationMy Cloud
APP_ENVEnvironment modeproduction
APP_KEYLaravel application key (auto-generated)base64:...
APP_DEBUGEnable debug mode — set false in productionfalse
APP_URLFull public URL of the frontendhttps://portal.yourcompany.com
API_URLFull URL of the backend APIhttps://api.yourcompany.com

Database​

VariableDescriptionExample
DB_CONNECTIONDatabase drivermysql
DB_HOSTDatabase host127.0.0.1
DB_PORTDatabase port3306
DB_DATABASEDatabase namecmp_db
DB_USERNAMEDatabase usercmp_user
DB_PASSWORDDatabase passwordstrong_password

Cache & Queue​

VariableDescriptionExample
CACHE_DRIVERCache backendredis
QUEUE_CONNECTIONQueue backend — use redis in productionredis
REDIS_HOSTRedis server host127.0.0.1
REDIS_PORTRedis port6379
REDIS_PASSWORDRedis auth (if set)null

Mail / Notifications​

VariableDescriptionExample
MAIL_MAILERMail driversmtp
MAIL_HOSTSMTP hostsmtp.mailgun.org
MAIL_PORTSMTP port587
MAIL_USERNAMESMTP username
MAIL_PASSWORDSMTP password
MAIL_ENCRYPTIONEncryption methodtls
MAIL_FROM_ADDRESSSender email addressnoreply@yourcompany.com
MAIL_FROM_NAMESender display nameMy Cloud

Keycloak SSO (optional)​

VariableDescription
KEYCLOAK_CLIENT_IDClient ID from Keycloak
KEYCLOAK_CLIENT_SECRETClient secret from Keycloak
KEYCLOAK_REALM_IDRealm name in Keycloak
KEYCLOAK_BASE_URLBase URL of your Keycloak server

See Keycloak Integration Setup for how to generate these values.

Payment Gateways (optional)​

VariableDescription
STRIPE_KEYStripe publishable key
STRIPE_SECRETStripe secret key
STRIPE_WEBHOOK_SECRETStripe webhook signing secret

Storage​

VariableDescriptionExample
FILESYSTEM_DISKDefault storage disklocal
AWS_ACCESS_KEY_IDS3-compatible storage key (if applicable)
AWS_SECRET_ACCESS_KEYS3-compatible storage secret
AWS_DEFAULT_REGIONStorage region
AWS_BUCKETS3 bucket name