Skip to content

Starting server as a service on ubuntu #729

Answered by kenetik
kenetik asked this question in Q&A
Discussion options

You must be logged in to vote

Was able to fix this by adding a WorkingDirectory= entry.

Example:

[Unit]
Description=Archive Box
After=network-online.target
Wants=network-online.target

[Service]
WorkingDirectory=/home/archivebox
ExecStart=/usr/local/bin/archivebox server 127.0.0.1:8000
User=archivebox
Group=archivebox
#Type=forking
Type=idle
Restart=always
RestartSec=15
RestartPreventExitStatus=0
TimeoutStopSec=10

[Install]
WantedBy=multi-user.target

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@pirate
Comment options

@kenetik
Comment options

Answer selected by kenetik
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants