mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-03-18 12:50:18 -05:00
[PR #2631] [MERGED] Fix persistent folder check within containers #2987
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/dani-garcia/vaultwarden/pull/2631
Author: @BlackDex
Created: 7/19/2022
Status: ✅ Merged
Merged: 7/22/2022
Merged by: @dani-garcia
Base:
main← Head:fix-2622-persistent-volume-check📝 Commits (1)
9a787ddFix persistent folder check within containers📊 Changes
18 files changed (+43 additions, -158 deletions)
View changed files
📝
docker/Dockerfile.j2(+0 -9)📝
docker/amd64/Dockerfile(+0 -9)📝
docker/amd64/Dockerfile.alpine(+0 -9)📝
docker/amd64/Dockerfile.buildx(+0 -9)📝
docker/amd64/Dockerfile.buildx.alpine(+0 -9)📝
docker/arm64/Dockerfile(+0 -9)📝
docker/arm64/Dockerfile.alpine(+0 -9)📝
docker/arm64/Dockerfile.buildx(+0 -9)📝
docker/arm64/Dockerfile.buildx.alpine(+0 -9)📝
docker/armv6/Dockerfile(+0 -9)📝
docker/armv6/Dockerfile.alpine(+0 -9)📝
docker/armv6/Dockerfile.buildx(+0 -9)📝
docker/armv6/Dockerfile.buildx.alpine(+0 -9)📝
docker/armv7/Dockerfile(+0 -9)📝
docker/armv7/Dockerfile.alpine(+0 -9)📝
docker/armv7/Dockerfile.buildx(+0 -9)📝
docker/armv7/Dockerfile.buildx.alpine(+0 -9)📝
src/main.rs(+43 -5)📄 Description
The previous persistent folder check worked by checking if a file
exists. If you used a bind-mount, then this file is not there. But when
using a docker/podman volume those files are copied, and caused the
container to not start.
This change checks the
/proc/self/mountinfofor a specific patern tosee if the data folder is persistent or not.
Fixes #2622
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.