# Systemd Service

Here follows an example file to configure pupcloud as a systemd service. I saved it into `/etc/systemd/system/pupcloud.service`.

```systemd
[Unit]
Description=Pupcloud

[Service]
Type=simple
User=myUser
Group=myUser
ExecStart=/home/myUser/local/pupcloud -r /mnt/myRootDir

[Install]
WantedBy=multi-user.target
```

Then you can `systemctl start pupcloud`, `systemctl status pupcloud`, `systemctl enable pupcloud` as normal.

{% hint style="warning" %}
**Always run as non-root** (as setup by lines 7-8 of the script). Pupcloud needs to be explicitly authorized to run as root, and it's seldom a good idea.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://germ.gitbook.io/pupcloud/guides/running-pupcloud/systemd-service.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
