elkarbackup
elkarbackup copied to clipboard
Running pre/post scripts in Docker not working with non-default uploads directory
Hi Elkarbackup team!
I have an instance of Elkarbackup on a local installation. To move away from this, I want move to the Docker version, which is deployed with Ansible. The issue arose when trying to run pre/post scripts during a job.
I deployed the Docker-version with a non-default directory (/backup/uploads) for SYMFONY__EB__UPLOAD__DIR.
When I later tried to run a few jobs, the pre-script of that job failed which led me to troubleshoot.
I found later that in the Docker container, the file /etc/sudoers.d/elkarbackup has a variable ELKARBACKUP_SCRIPTS which did not point to my specified directory (/backup/uploads), but still to the default value (/app/uploads).
After manually changing the line, the jobs ran fine.
This is using the latest version of the image, 2.1.0.
TL;DR - The variable SYMFONY__EB__UPLOAD__DIR in my mind should also change the variable ELKARBACKUP_SCRIPTS in the /etc/sudoers.d/elkarbackup file for pre/post-scripts to work with non-default script directories.
You're right.
Can I ask why did you change the default directory instead of using docker volumes pointing to the default configuration?
Thanks