Navigation Menu

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

nixos/module/deluge: fix directory ownership. #67852

Closed
wants to merge 1 commit into from

Conversation

gleber
Copy link
Contributor

@gleber gleber commented Aug 31, 2019

Fixes nixos/tests/deluge.nix test.

The pre-script was failing with 'Permission denied' errors. I have tracked it
down to the unusual permissions on /var/lib/deluge/.config directory tree.
Additionally errors of form "Detected unsafe path transition xxx → yyy during
canonicalization of zzz" were printed by systemd. This makes it work.

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
Notify maintainers

cc @infinisil @domenkozar @ebzzry @davidtwco

Fixes nixos/tests/deluge.nix test.

The pre-script was failing with 'Permission denied' errors. I have tracked it
down to the unusual permissions on /var/lib/deluge/.config directory tree.
Additionally errors of form "Detected unsafe path transition xxx → yyy during
canonicalization of zzz" were printed by systemd. This makes it work.
@gleber
Copy link
Contributor Author

gleber commented Aug 31, 2019

@GrahamcOfBorg test deluge

Copy link
Contributor

@flokli flokli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change to use tmpfiles.d to manage the directory layout declaratively was intentional.

The error message looks more as if there are some symlinks involved / cf https://github.com/systemd/systemd/blob/master/src/tmpfiles/tmpfiles.c#L883

Can you elaborate on how your filesystem layout looks there?

@flokli
Copy link
Contributor

flokli commented Aug 31, 2019

also cc @aanderse

@aanderse
Copy link
Member

@gleber please paste your deluge configuration.

@gleber
Copy link
Contributor Author

gleber commented Sep 1, 2019

@flokli Yes, I suspected that :) The issue is that it does not work for me and the appropriate test in the repo fails on master. I am happy to get it fixed with using tmpfiles.d, but my patience ran out when trying to figure out what is going wrong in the systemd land.

@aanderse It is a bit messy, hard to get to get it shared. But the issue is reproducible with nix-build nixos/tests/deluge.nix. This PR fixes this test to pass.

I am happy to get hints how to fix it with tmpfiles.d mechanisms and update the PR.

@gleber
Copy link
Contributor Author

gleber commented Sep 1, 2019

Closing in favor of #67888

@gleber gleber closed this Sep 1, 2019
@gleber gleber deleted the fix-deluge-dirs branch September 1, 2019 15:43
@gleber gleber restored the fix-deluge-dirs branch July 7, 2020 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants