mirror of
https://github.com/owncast/owncast.git
synced 2024-11-21 20:28:15 +03:00
Banjo/owncast systemd service (#749)
* Adding systemd service files to ..\examples * Update owncast-systemd-service.md * Update owncast-systemd-service.md * Update owncast-systemd-service.md * Update owncast-systemd-service.md * correct slash syntax * Update owncast-sample.service with generic paths * Adding instructions to owncast-systemd-service.md
This commit is contained in:
parent
3ae6f82701
commit
d1844fc814
2 changed files with 54 additions and 0 deletions
13
examples/owncast-sample.service
Normal file
13
examples/owncast-sample.service
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
[Unit]
|
||||||
|
Description=Owncast Service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
WorkingDirectory=[path_to_owncast_root_directory]
|
||||||
|
ExecStart=[path_to_owncast_executable]
|
||||||
|
Restart=on-failure
|
||||||
|
RestartSec=5
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
41
examples/owncast-systemd-service.md
Normal file
41
examples/owncast-systemd-service.md
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
This can be any text that makes sense to you.
|
||||||
|
```
|
||||||
|
[Unit]
|
||||||
|
Description=Owncast Service
|
||||||
|
```
|
||||||
|
|
||||||
|
This is where the "functional" parts of the service live.<br />
|
||||||
|
```
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
WorkingDirectory=[path_to_owncast_root_directory]
|
||||||
|
ExecStart=[path_to_owncast_executable]
|
||||||
|
Restart=on-failure
|
||||||
|
RestartSec=5
|
||||||
|
```
|
||||||
|
`WorkingDirectory` should be where you want the owncast folder to live.<br />
|
||||||
|
|
||||||
|
**Example:**<br />
|
||||||
|
```WorkingDirectory=/var/www/owncast```
|
||||||
|
|
||||||
|
Similarly the `ExecStart` is the actual owncast binary.<br />
|
||||||
|
|
||||||
|
**Example:**<br />
|
||||||
|
```ExecStart=/var/www/owncast/owncast```
|
||||||
|
|
||||||
|
```
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
```
|
||||||
|
This just means, use runlevel 3 non-graphical.
|
||||||
|
|
||||||
|
|
||||||
|
**INSTALLATION**
|
||||||
|
Just create the file in your systemd configuraiton directory (typically /etc/systemd/system/), and update the systemd daemon with:
|
||||||
|
```$sudo systemd daemon-reload```
|
||||||
|
|
||||||
|
**USAGE**
|
||||||
|
Currently the following options work
|
||||||
|
- Start
|
||||||
|
- Stop
|
||||||
|
- Status
|
Loading…
Reference in a new issue