This repository contains sample configuration for docker-compose
to be able to run Survey Solutions Headquarters with docker.
Docker images are hosted by Docker Hub: https://hub.docker.com/r/surveysolutions/surveysolutions
While those compose files can be used to run in production environment. We strongly recommend to run Postgres database on separate server or using managed solutions from Cloud providers.
This can be literally any linux server hosted on any cloud or on-prem provider with public IP or DNS name.
This can be any domain You own. If you don't have one - there is plenty free domains available.
A
record for this domain should point to public IP address of Your server
- Clone or fork this repository
- Adjust
.env
file with Your own domain name. Default value will only work with non-ssl version of configuration.
Use run.sh
file to spin up HQ without SSL. In this mode default value for HQ_HOST=hq.lvh.me
in .env
will for localhost connections
Use run.ssl.sh
file to spin up HQ with Automatic SSL support.
Automatic SSL is handled by Traefik
proxy server via Let's Encrypt
There is a project that can help You to automatically periodically backup HQ database: https://github.com/prodrigestivill/docker-postgres-backup-local
Configuration in docker-compose can be found here at docker-compose.backup.yml
To run with backups You can use following commands:
# Without SSL
docker-compose -f docker-compose.yml -f docker-compose.backup.yml up -d
# With SSL
docker-compose -f docker-compose.yml -f docker-compose.ssl.yml -f docker-compose.backup.yml up -d
While running Postgres instance in docker is viable solution, we strongly recommend to run Postgres in separate server or use "managed" solutions provided by cloud providers(i.e. Amazon RDS, Azure Database for PostgreSQL, Google Cloud SQL, etc...)