-
-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DB_DATABASE
path not respected by entrypoint script.
#192
Comments
Good day Mattcl. I'm attempting to do the same thing with a kubernetes cluster. How did you fix the issue with the path not mapping/persisting? My setup is trying to mount an Azure File Share and use that as the database persistent volume. How did you mount /2fauth as a persistent volume? |
I just mounted at from my kustomize configs
|
Thanks for the help. Does the database persist even when the docker image is recreated/updated? For example, if I deploy the docker image with Azure Pipelines, make a change and redeploy with Azure Pipelines, it still has the same database? |
I'm mounting a persistent volume, so it'll persist through pod rollouts and power failures (assuming I don't lose my drives). My cluster is local, so the plugins I have available to me are different, but I assume you just need to declare the appropriate resources in AKS https://learn.microsoft.com/en-us/azure/aks/concepts-storage#persistent-volumes. This is probably not the right thread for that, however. |
@mattcl I just pushed a fix on the dev branch for this issue. |
@Bubka This appears to work, thank you. Feel free to close this issue if you'd like. |
Great, thx for the feedback |
Describe the bug
When setting
DB_DATABASE
to something other than/srv/database/database.sqlite
,entrypoint.sh
creates the database at/2fauth/database.sqlite
then links it to a hardcoded/srv/database/database.sqlite
. This causes the container to crash withDatabase file at path [<your path>] does not exist
To Reproduce
Steps to reproduce the behavior:
DB_DATABASE
Expected behavior
I would expect the entrypoint to create the database at the location specified by
DB_DATABASE
Additional context
For context, I'm sticking with sqlite for now, but trying to persist the db on a persistent volume claim on my kubernetes cluster. What I am going to do is just mount the
/2fauth
folder as my persistent volume, but the behavior withDB_DATABASE
is still probably an issue.The text was updated successfully, but these errors were encountered: