Last active
February 2, 2024 06:52
-
-
Save paul-chambers/f83399c4e52baf0fb0f5b3cd37f7d254 to your computer and use it in GitHub Desktop.
install autobrr
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=autobrr service | |
After=syslog.target network-online.target | |
[Service] | |
Type=simple | |
User=autobrr | |
Group=media | |
UMask=002 | |
ExecStart=/var/lib/autobrr/bin/autobrr --config=/var/lib/autobrr | |
[Install] | |
WantedBy=multi-user.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -x | |
url=$(curl -s https://api.github.com/repos/autobrr/autobrr/releases/latest | grep download | grep linux_x86_64 | cut -d\" -f4) | |
archive="/tmp/autobrr.tar.gz" | |
homedir="/var/lib/autobrr" | |
addgroup --gid 2000 media | |
adduser --system --uid 2100 --ingroup media --home "${homedir}" autobrr | |
wget -O "${archive}" "${url}" | |
mkdir -p "${homedir}/bin" | |
tar -C "${homedir}/bin" -xzf "${archive}" | |
chown -R autobrr:media "${homedir}/bin" | |
sudo ln -s "${homedir}/bin/autobrrctl" /usr/bin | |
gist="https://gist.githubusercontent.com/paul-chambers/f83399c4e52baf0fb0f5b3cd37f7d254" | |
wget -O /lib/systemd/system/autobrr.service "${gist}/raw/81a86a91fb2a942681ed79690a2b4711172b55be/autobrr.service" | |
sudo systemctl daemon-reload \ | |
&& sudo systemctl enable --now autobrr.service \ | |
&& sudo systemctl status autobrr.service |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment