How to shift to a database outside of docker?

Hello everyone. To move the site to production, we want to use proper database instances that are not just docker containers running beside the app in a VPS. We tried to find configuration files in code where connection strings are present such that we can change them to our liking.

So far, we have only found configuration for the main database at path /opt/tao-ce/construct/backend/config/generis/persistences.conf.php. But there are two more databases inside the pgsql container. Where can we find the configuration for them?

I found this out! The other two database urls are configured at /etc/tao-ce/setup/envs/scoring/service.env and /etc/tao-ce/setup/envs/scoring/backend.env.

Note that after editing any database url, you will need to restart the systemd services like this:
systemctl restart tao-ce.scoring.*
systemctl restart tao-ce.construct.backend.service # if you changed the db url in construct as well.

However, after configuring them with my local MariaDB database, the scoring functionality isn’t working properly. Particularly, after submitting the scores for a question, it still shows up as scoring pending. The scoring values are saved but the scoring status isn’t updated.

Actually you want to update the database urls at /usr/local/libexec/tao-ce/setup/apps/scoring.libsonnet, then run systemctl restart tao-ce.*. If you update just the envs then when you restart the container the envs will revert.