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/smokeping: replace smokeping.fcgi with a symlink #71137

Merged
merged 2 commits into from Oct 23, 2019

Conversation

erictapen
Copy link
Member

Motivation for this change

This fixes a regression from bb649d9.
There were permission problems, when the preStart script tried to copy the smokeping.fcgi file over the old file.

834fi85dzixkalmk383gp0v9ps6rd4gy-unit-script-smokeping-pre-start[1545]: cp: cannot create regular file '/var/lib/smokeping/smokeping.fcgi': Permission denied
Things done

As I don't see any reason why smokeping.fcgi should be writable, I replaced it with a symlink from /nix/store.

Warning: If you experience this problem, applying this patch and rebuilding your system is not enough:

  • You need to manually remove the old file with higher privileges than smokeping user has.
  • I also needed to restart thttpd.service.

This needs to be backported to nixos-19.09.

  • 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 @cransom as they introduced the module.

This fixes a regression from bb649d9.
There were permission problems, when the preStart script tried to copy
the smokeping.fcgi file over the old file.
Copy link
Contributor

@cransom cransom left a comment

Choose a reason for hiding this comment

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

ok by me. cool to know someone uses it.

@erictapen
Copy link
Member Author

Thanks for the module ;)

@wizeman
Copy link
Member

wizeman commented Oct 23, 2019

Looks good and fixes the issue for me. Thanks!

@wizeman wizeman merged commit 4cd2cb4 into NixOS:master Oct 23, 2019
@wizeman
Copy link
Member

wizeman commented Oct 23, 2019

Backported to 19.09.

@erictapen
Copy link
Member Author

Great, thanks for merging.

@erictapen
Copy link
Member Author

for reference: backport is in 990f5f4

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