Location for the OpenLMIS v3+ SELV deployment scripts and resources
To fully support all required features, the PostgreSQL database has to be adjusted.
All necessary config files are available in deployment/shared/pgdata
directory. Due to
lack of required permissions to access the volume directly while being outside of the server,
the files has to be moved to a temporary location at first:
- Move the files to the temporary directory on the server:
scp -r deployment/shared/config/pgdata <user>@<put target server address here>:/tmp
- Enter the server via SSH
- Switch to superuser in order to gain required permissions to modify the db volume (
sudo su
) - Move all necessary files to the volume:
cp -rf /tmp/pgdata /var/lib/docker/volumes && rm /tmp/pgdata -r
If the database has been wiped out, or not yet initiated it's possible that the initial credentials for the auth server
are not configured and the UI can't connect to the server properly (and user receives HTTP code 401
when trying to log in). In order to fix that, values for both server and UI client in
auth.oath_clent_details
table should reflect the values from env file (settings.env
or
.env-restore
). authorizedgranttypes
column helps to establish if the credentials are for the
server side (client_credentials
) or for the UI side (password
).
If for some reason extensions specified in this file were not created properly - it might result in errors while executing the initial SQL migrations. In this case, the extensions should be created manually:
DROP EXTENSION IF EXISTS "uuid-ossp"; CREATE EXTENSION "uuid-ossp";
DROP EXTENSION IF EXISTS "postgis"; CREATE EXTENSION "postgis";