Closed normanjaeckel closed 1 year ago
Which ones?
I have worked at the entrypoint
( moved it, extract vars, add reading FILE vars). At the moment I think the situation should be okay.
I think https://github.com/OpenSlides/openslides-media-service/blob/openslides4-dev/scripts/entrypoint.sh#L6 is still wrong. The password should be read from secret file and not from env var directly. Please see the correspondent issue in datastore: https://github.com/OpenSlides/openslides-datastore-service/pull/164
See especially https://github.com/jsangmeister/openslides-datastore-service/blob/0847086340c56d737a14fd03cb08a3a9286becae/scripts/system/export-database-variables.sh how the datastore sets PGPASSWORD
(which is silently used by the psql
command).
The variable is set in https://github.com/OpenSlides/openslides-media-service/blob/openslides4-dev/scripts/service_env.sh. But I agree that this should be done analogous to the datastore (especially should it not be possible to provide the password directly via an env var).
The entrypoint (https://github.com/OpenSlides/openslides-media-service/blob/openslides4-dev/entrypoint.sh) contains wrong environment vars. At least the postgres password should be read from secret file. Without this fix the prod setup would be broken.