Learn how to self-host Latitude in production mode
.env
configuration filedocker compose
.
.env
file with your production settings. The following key configurations are available:TRAEFIK_ACME_EMAIL
: Email address used for Let’s Encrypt ACME registration. Required for issuing and renewing SSL certificates. It is also used to receive expiration and renewal notifications.TRAEFIK_ADMIN_PASS
: Passwords must be hashed using MD5, SHA1, or BCrypt. Read more: https://doc.traefik.io/traefik/middlewares/http/basicauth/
Example command to generate a password for user admin:
POSTGRES_USER
and POSTGRES_PASSWORD
: Database credentialsDATABASE_URL
: PostgreSQL connection stringQUEUE_PORT
and QUEUE_HOST
: Redis queue configurationCACHE_PORT
and CACHE_HOST
: Redis cache configurationAPP_DOMAIN
: Your domain (e.g., latitude.so
)APP_URL
: Full URL to your applicationGATEWAY_HOSTNAME
: API gateway hostnameGATEWAY_SSL
: Enable/disable SSLMAIL_TRANSPORT
: smtp
, mailgun
, mailpit
- default
transport is mailpit
MAILGUN_EMAIL_DOMAIN
: Email domain for sending emailsFROM_MAILER_EMAIL
: Sender email addressMAILGUN_MAILER_API_KEY
: Mailgun API key (optional)DISABLE_EMAIL_AUTHENTICATION
: Disable email authentication (optional, default: false
)MAIL_TRANSPORT
is set to smtp
, you must provide the following environment variables:
SMTP_HOST
: The SMTP server host (e.g., smtp.gmail.com
)SMTP_PORT
: The SMTP port number (e.g., 465
for SMTPS or 587
for STARTTLS)SMTP_SECURE
: Set to true
for SMTPS (465
) or false
for STARTTLS (587
)SMTP_USER
: Your email address used for authentication (e.g., your_email@gmail.com
)SMTP_PASS
: The password for your email account (use an app password if using Gmail)SMTP_SECURE
set to true
for SMTPS or false
for STARTTLS). This is crucial for protecting your email credentials and the contents of your email.DRIVE_DISK
: Choose between local
or s3
for file storage
local
file storage configuration:
s3
AWS S3 storage configuration:
gateway.latitude.localhost
)app.latitude.localhost
)ws.latitude.localhost
)http://app.latitude.localhost
http://gateway.latitude.localhost
http://ws.latitude.localhost
http://localhost:8090
./docker/pgdata
..env
filelocalhost
. Remember to configure
your .env
file accordingly.