Added LimitNOFILE option in systemd configuration #94
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
For servers it's important to have an option to set the maximum open files. Simply adding this in /etc/security/limits.conf won't work because systemd ignores this file. Systemd has an option to set LimitNOFILE in the configuration file, so I added this option.
-- end pull info --
I also tried to solve the systemd spaces in paths issues (#63 , #90 ). I tried using the systemd-escape command (instead of the cmd, cmdEscape template functions). But this didn't worked. Seems like they did change the space handing between different versions of systemd.
service_linux.go:
However, I did found a solution for #90
service_systemd_linux.go (line 165)
Setting the ExecStart option that way should solve the problem, but this needs more testing.
More info: systemd/systemd#2132