diff options
| author | alex <[email protected]> | 2026-07-13 16:44:51 +0200 |
|---|---|---|
| committer | alex <[email protected]> | 2026-07-13 16:44:51 +0200 |
| commit | 1b430cb695dd541f80223d743f378135064f4fec (patch) | |
| tree | 7426e91a25530379372c3d1570819180fbaebe32 /[email protected] | |
| download | spotify-into-discord-main.tar.xz spotify-into-discord-main.zip | |
Diffstat (limited to '[email protected]')
| -rw-r--r-- | [email protected] | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/[email protected] b/[email protected] new file mode 100644 index 0000000..567a782 --- /dev/null +++ b/[email protected] @@ -0,0 +1,22 @@ +[Unit] +Description=Librespot instance for %I +After=network.target + +[Service] +Type=simple + +# Create the pipe and cache folders automatically +ExecStartPre=/usr/bin/mkdir -p /opt/spotify-bot/pipes +ExecStartPre=/usr/bin/mkdir -p /var/cache/librespot/%I +ExecStartPre=/usr/bin/rm -f /opt/spotify-bot/pipes/%I_pipe +ExecStartPre=/usr/bin/mkfifo /opt/spotify-bot/pipes/%I_pipe + +# Launch Librespot using OAuth and saving credentials to a local cache folder +ExecStart=/usr/bin/librespot -n "Server Speaker (%I)" --backend pipe --device /opt/spotify-bot/pipes/%I_pipe --cache /var/cache/librespot/%I --enable-oauth + +Restart=always +RestartSec=10 + +[Install] +WantedBy=multi-user.target + |
