-
-
Notifications
You must be signed in to change notification settings - Fork 14.1k
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
miniupnpd: add service #11548
miniupnpd: add service #11548
Conversation
By analyzing the blame information on this pull request, we identified @edolstra, @bjornfor and @offlinehacker to be potential reviewers |
fd00a0c
to
70d354a
Compare
{ | ||
options = { | ||
services.miniupnpd = { | ||
enable = mkOption { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use mkEnableOption
.
@jagajaga Thanks, based all of this on another service so I had no idea Anyway, all fixed, also fixed the descriptions that made no sense. |
{ | ||
options = { | ||
services.miniupnpd = { | ||
enable = mkEnableOption "Enable the MiniUPnP daemon."; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As an argument you need to write just the name of option :)
In this case you need to write just the name of service.
You can search through nixpkgs and find some examples.
Oh I did look at examples, but seem to have missed that. ;) |
Btw why is there no |
Please don't merge yet, the |
Is it possible to run miniupnpd in it's own user instead of root ? |
@zimbatm You tell me haha. This thing has bascially zero documentation and I'm not exactly an expert in upnp. |
@jgillich Looking at Gentoo again, it seems like it's touching iptables so probably needs root access. Their init script also runs a |
ArchLinux seem to be doing the same: https://projects.archlinux.org/svntogit/community.git/tree/trunk/miniupnpd.systemd?h=packages/miniupnpd |
They also call a script to create the rules before starting the service, I'm currently doing that via |
Yeah, I wonder how it interacts with the NixOS built-in firewall, are the rules not going to overlap ? |
By "they" I meant Arch and Gentoo. :) miniupnpd only uses the chains set via |
👍 |
Not sure if there are any more common config options to add.