The docker image contains the following components:
- agosense.symphony application
- Java environment
- PostgreSQL database
The docker image is published through our docker registry
wagner.agosense.com:28443, the image name is
and tags are created for each release.
If you do not yet have access to our docker registry, raise a support ticket
Use a volume to persist the content of the database independent of the docker
container. The volume target is
An additional volume is advisable for the target
/home/app/conf to make
sure configuration changes are also persisted outside the container.
|NUCLEUS_HTTP_ENABLED||Used to enable the plain http port, e.g. when operating behind a reverse proxy that enforces https towards users|
|SYMPHONY_JAVA_VM_OPTIONS||Used to apply custom Java VM Options|
version: '3.8'services: symphony: container_name: symphony image: wagner.agosense.com:28443/symphony:<version> environment: - SYMPHONY_JAVA_VM_OPTIONS=-Xms1G -Xmx1G volumes: - symphony-db-data:/home/db/data - symphony-conf:/home/app/conf ports: - 8443:8443 volumes: symphony-db-data: null symphony-conf: null
The docker container engine acts as a DHCP server for the containers and their assignemnt to ip addresses.
To prevent symphonys activation hash from changing randomly, you should make sure to connect the container to a predefined network and define a fixed ip address.
Add this directly under the
symphony service configuration:
networks: symphony: ipv4_address: 172.31.0.2
Add this to the global configuration:
networks: symphony: name: symphony
The docker image always includes an up-to-date version of the PostgreSQL database. The database installation
itself is located in the
/home/db folder in the docker image.
If you wish to execute SQL commands you can enter the docker container like:
docker exec -it symphony bash
This will open the shell inside the docker container, now run the following commands to enter the PostgreSQL shell:
cd /home/dbbin/psql -U app
This will connect the database with the default user
app. When prompted for the password type in
You can now use the PostgreSQL shell to execute SQL commands. See
PostgreSQL documentation for further details.
The database used is also called
To backup data you can use the command
pg_dump. To restore the data
psql can be used.
An example command for dumping the complete symphony database (classic and one) would be:
docker exec -i symphony /home/db/bin/pg_dump -U app app > /dump.sql
PostgreSQL documentation provides a wide range of options to customize the dump e.g. excluding specific tables (like reporting tables) to limit the size of the dumps or splitting the dump file to handle growing database size.
To load the dump back (e.g. in case of a crash of the server) you would follow these steps:
Assuming symphony is running again, it has created a new empty database initially. Before restoring the existing data you need to remove the existing schemas so they can be recreated based on the dump file. To do so you need to enter the PostgreSQL shell first:
cd /home/dbbin/psql -U app
Next you need to drop the existing schemas:
drop schema public cascade;drop schema symphony_main cascade;
Then exit the PostgreSQL shell, copy the dump file into the docker container and enter the following command to restore the data:
bin/psql --user app app < /dump.sql
This will recreate the two schemas along with all data that was included in the backup.