Univention Bugzilla – Bug 52552
Make DockerScriptInit configurable
Last modified: 2021-03-24 10:53:45 CET
Currently there is no way to edit the DockerScriptInit of an app. For the Dashboard Database, which is a containerized Prometheus, the only way to change retention rules like saving period or database size is via flag on start as set by DockerScriptInit. (see https://github.com/prometheus/prometheus/issues/6188 for the reasoning) While there might be a sufficient way to rewrite the Prometheus config, my guess is that with a more containerized UCS5 the need to change the ScriptInit will arise for other apps too.
How is this flag passed to the container? Via environment variable? Can you please provide an example for a docker command that would configure the desired value?
I guess the word flag is ambiguous in this context. Speaking of it in terms of Golang flags, you have to supply it as a command option like: "docker run prometheus --storage.tsdb.retention.time=30d --config.file=/etc/prometheus/prometheus.yml ..." which also would mean changing CMD in a Dockerfile or "command:" in docker-compose. As stated in linked discussion, there is and will be no other way for now to configure this via file, env or similar.
*** This bug has been marked as a duplicate of bug 52839 ***