mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-03-02 22:57:43 -05:00
systemd unit example #1611
Labels
No labels
1%
blocked-by: skyhook
bug
connection
discussion
docs
download-client
enhancement
external-bug
indexer
missing-description
mono-bug
naming
needs-to-be-tested
needs-triage
one-day-maybe
parsing
platform: linux
platform: macos
platform: windows
priority:high
priority:low
priority:medium
priority:medium
proposal
skyhook/services
suboptimal
support
task
ui-only
up-for-grabs
v3
v4
waiting-for-contributor
waiting-for-info
wip
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/Sonarr#1611
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Taloth on GitHub (Jul 28, 2017).
@untoreh
I just noticed your changed to the systemd unit example, even though it was a couple of weeks ago:
https://github.com/Sonarr/Sonarr/wiki/Autostart-on-Linux/_compare/4903e93095e0e9e5efa0782a56655034591671f1...7cf87655efa014b44a80ea52dfeeaf628c62ec0d#diff-1f798ffb8093a81af913ecf9128a2be0R225
Personally I think this is a bad choice:
The change assumes that the specified user exists, and assumes that the user home folder is located there, and has the username located in several locations of the file.
Further more, Sonarr already creates the directory as needed which should go fine since the user should have write permissions in their own home directory.
As such, I believe the ExecStartPre commands are superfluous and error prone.
I'm opening this issue in the hopes of getting a response, otherwise I'll revert the change after a while.
@ghost commented on GitHub (Jul 29, 2017):
sonarr was failing to start because wasn't creating such folder, systemd behaves in a manner that vars substitution within
ExecStartPrewith elevated privileges are relative to root and notUser=. The username is the one used in the package (ubuntu at least). This stuff should probably belong in the packages@Taloth commented on GitHub (Jul 29, 2017):
I think that's something to be investigated, chances are the home directory wasn't created or had the wrong permissions.
I know, but using absolute paths there is just a workaround, and as I said error prone.
Afaik the package has no username.
We're planning to do so in v3 together with the package rename to Sonarr, but we can't do that now.
The changes you made are specific for one environment, however Sonarr is installed on many different OSes which have different locations for mono, user homes etc, including seedboxes, NAS'.
@ghost commented on GitHub (Jul 29, 2017):
iirc sonarr assumes
.config/is already presentyou're right, it is used here
yes although I figured since the script already required manual editing, offering a working example wouldn't hurt, anyway change as you want
@markus101 commented on GitHub (Dec 4, 2017):
@Taloth can we clean this up and close?
@Taloth commented on GitHub (Dec 5, 2017):
I rather move it to the v3 milestone (since the v3.0 installer should include the appropriate unit file)
@markus101 commented on GitHub (Jun 3, 2018):
systemd file will be included with eh debian package (and any other packages we add).