grav/pages/04.plexpy/docs.md

1.2 KiB

title
PlexPy

PlexPy

Clone the CouchPotato GitHub Repo

Run git clone https://github.com/JonnyWong16/plexpy.git /opt/PlexPy

User Management

For security it is best to run a service with a specific user and group. You can create one using the following command: Add to the plexpy group any users you wish to be able to easily manage or access files downloaded through Deluge, for example:

sudo adduser --system  --gecos "PlexPy Service" --disabled-password --group --home /var/lib/plexpy plexpy
sudo adduser tanshu plexpy

Autostart with systemd

Create the file /etc/systemd/system/plexpy.service containing the following:

sudo nano /etc/systemd/system/plexpy.service
[Unit]
Description=PlexPy Daemon
After=network.target

[Service]
User=plexpy
Group=plexpy

Type=simple
ExecStart=/opt/PlexPy/PlexPy.py --quiet --daemon --nolaunch --config /etc/plexpy/config.ini --datadir /var/lib/plexpy
GuessMainPID=no
Type=forking

[Install]
WantedBy=multi-user.target

Enable the service with:

systemctl enable /etc/systemd/system/plexpy.service
systemctl start plexpy
systemctl status plexpy

Finally

Open your browser and go to: http://localhost:8181/