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/freeswitch: Unit improvements and add fs_cli #89558
Conversation
@@ -95,9 +95,11 @@ in { | |||
-conf ${configPath} \\ | |||
-base /var/lib/freeswitch"; | |||
ExecReload = "${pkg}/bin/fs_cli -x reloadxml"; | |||
Restart = "always"; | |||
Restart = "on-failure"; |
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.
What is the use case for this?
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.
This way, fs_cli -x 'fsctl shutdown elegant'
works without starting the daemon afterwards, while fs_cli -x 'fsctl crash'
will cause it to be restarted afterwards.
}; | ||
}; | ||
environment.systemPackages = pkg; |
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.
error: The option value `environment.systemPackages' in `nixpkgs/nixos/modules/services/misc/freeswitch.nix' is not of type `list of packages'.
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.
Oh, forgot to git add
:/ Force-pushed it
This switches the unit to Restart=on-failure and switches the CPU policy to fifo (the daemon tries to do that itself, but is denied permission). Also add the package to $PATH to be able to use fs_cli easily.
This switches the unit to Restart=on-failure and switches the CPU policy
to fifo (the daemon tries to do that itself, but is denied permission).
Also add the package to $PATH to be able to use fs_cli easily.
Motivation for this change
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)