Redmine: REDMINE_DATA_TO_PERSIST
without ${REDMINE_CONF_DIR}/...
is not working
#76111
Labels
REDMINE_DATA_TO_PERSIST
without ${REDMINE_CONF_DIR}/...
is not working
#76111
Name and Version
bitnami/redmine:6.0.1-debian-12-r1
What architecture are you using?
amd64
What steps will reproduce the bug?
REDMINE_DATA_TO_PERSIST
with the valuefiles plugins public/plugin_assets
. This excludes${REDMINE_CONF_DIR}/configuration.yml
and${REDMINE_CONF_DIR}/database.yml
from the default persistence settings.Explanation of the Issue
During the first start, the instance creates all necessary configuration files (in
${REDMINE_CONF_DIR}
and other directories likefiles
andplugins
). It also sets up and migrates the database.On subsequent starts, the
redmine_initialize
function checks the app's status usingis_app_initialized
. It detects a non-empty$persist_dir
(due to the existingfiles
directory) and proceeds to the else part of the initialization logic.containers/bitnami/redmine/6/debian-12/rootfs/opt/bitnami/scripts/libredmine.sh
Line 133 in 4ec23c9
containers/bitnami/redmine/6/debian-12/prebuildfs/opt/bitnami/scripts/libpersistence.sh
Lines 116 to 124 in 4ec23c9
This process assumes that
configuration.yml
anddatabase.yml
are already set up and tries to use them automatically. However, this assumption leads to a failure.What is the expected behavior?
The desired outcome was to deploy an instance that doesn't persist configuration files on the volume (for security reasons). Instead, it should generate
configuration.yml
anddatabase.yml
based on the latest environment variables during each boot.What do you see instead?
While the first boot appears successful, all subsequent restarts fail with errors:
Additional information
The original plan was to migrate an old deployment to Helm, using an external database and custom persistent storage for files. The intention was to move the database to a new external location and transfer data to the new custom persistent storage. However, because the data migration created a files directory in the expected location,
redmine_initialize
didn't attempt to create a newdatabase.yml
. The presence of the files directory causedredmine_initialize
to return true, assuming the app was already initialized.The text was updated successfully, but these errors were encountered: