aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorLiam <[email protected]>2021-01-05 02:40:52 +0000
committerGitHub <[email protected]>2021-01-05 02:40:52 +0000
commita8e37fa0c821d8ea1032a83f4aa0c5169508c4b8 (patch)
tree3d40c3b3843e04db5beb607995327c8888972a44 /docs
parentCreate sample service file (diff)
downloadhost.fuwn.me-a8e37fa0c821d8ea1032a83f4aa0c5169508c4b8.tar.xz
host.fuwn.me-a8e37fa0c821d8ea1032a83f4aa0c5169508c4b8.zip
Create systemd guide
Diffstat (limited to 'docs')
-rw-r--r--docs/systemd.md22
1 files changed, 22 insertions, 0 deletions
diff --git a/docs/systemd.md b/docs/systemd.md
new file mode 100644
index 0000000..f68ff2c
--- /dev/null
+++ b/docs/systemd.md
@@ -0,0 +1,22 @@
+### Service config for systemd
+The file chibisafe-example.service is to be moved to `/etc/systemd/system/chibisafe.service`
+
+You will need to edit the parameters:
+- `User` to be the username/uid of your chibisafe instance
+- `WorkingDirectory` to the **FULL** path to your chibisafe, `/home/chibisafe/chibisafe` for example.
+- `EnvironmentFile` the same as the above, with the addition of `/.env`, `/home/chibisafe/chibisafe/.env`
+
+```[Unit]
+Description=chibisafe, easy to use file uploader
+After=network.target
+
+[Service]
+Type=simple
+User=chibisafe
+WorkingDirectory=/home/chibisafe/chibisafe
+EnvironmentFile=/home/chibisafe/chibisafe/.env
+ExecStart=/usr/bin/npm run start
+Restart=always
+
+[Install]
+WantedBy=multi-user.target```