Skip to content
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

fix: handle volume permissions correctly #198

Merged
merged 4 commits into from
Dec 20, 2024

Conversation

tiero
Copy link
Member

@tiero tiero commented Dec 14, 2024

Fix volume permissions for Linux users

This PR fixes permission issues with mounted volumes, particularly on Linux systems where users were experiencing root ownership problems.

Testing on macOS

# 1. Make sure Docker Desktop is running
# 2. Build and test
make build

# 3. Run test cycle with the new binary
sudo rm -rf ~/Library/Application\ Support/Nigiri
./build/nigiri-darwin-arm64 stop --delete
./build/nigiri-darwin-arm64 start

# 4. Verify permissions (should show your user, not root)
ls -la ~/Library/Application\ Support/Nigiri/volumes/bitcoin/

Expected output should show your user owning the files:

drwxr-x---   4 <your-user>  staff  128 Dec 18 19:19 .
drwxr-x---   7 <your-user>  staff  224 Dec 18 19:19 ..
-rw-r-----   1 <your-user>  staff  295 Dec 18 19:19 bitcoin.conf
drwx------  12 <your-user>  staff  384 Dec 18 19:19 regtest

@tiero
Copy link
Member Author

tiero commented Dec 18, 2024

I managed to test on a debian VM. Now also Bitcoin Core datadir is owned by the user, and not root!

image

@tiero tiero requested a review from altafan December 18, 2024 18:25
@tiero tiero merged commit a893d54 into vulpemventures:master Dec 20, 2024
3 checks passed
@tiero tiero mentioned this pull request Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant