Deploy to Production¶
This guide covers deploying D2S to a production environment.
Work in progress
This guide is under development. For now, refer to the Local Development Setup guide as a starting point and adjust for your production environment.
Overview¶
A production deployment of D2S involves:
- Configuring environment variables with production-appropriate values (secure secrets, HTTPS domain, SMTP settings).
- Building Docker images from the source or using prebuilt images.
- Running the containers behind a reverse proxy with TLS.
- Setting up persistent storage volumes for uploaded data.
Key configuration changes for production¶
- Set
HTTP_COOKIE_SECURE=1inbackend.envto enforce HTTPS-only cookies. - Set
API_DOMAINto your production domain (e.g.,https://d2s.example.org). - Use a strong, unique value for
SECRET_KEY. - Configure SMTP settings (
MAIL_ENABLED=1,MAIL_SERVER, etc.) for transactional email. - Set
TILE_SIGNING_SECRETto a secure random string. - Adjust
UVICORN_WORKERSandLIMIT_MAX_REQUESTSfor your expected load.