-
Notifications
You must be signed in to change notification settings - Fork 276
Medusa installation Debian Ubuntu
The following instructions are for installing Medusa on Ubuntu 14.04 and newer or Debian 7.0 and newer.
The installation assumes that you're not using the root user to install/run Medusa. The entries for user:group throughout the document will be set as medusa:medusa and you will have to modify it if you want it to match your user configuration.
-
Update repositories and install dependencies. This will install mediainfo, unrar and git to pull the repo
sudo apt-get update && sudo apt-get install unrar git-core openssl mediainfo
Install Python 3:
Ubuntu: Follow this well written guide over at Real Python.
Debian 7.0 - 8.0: Follow this well written guide over at Real Python.
Debian 9 and newer:
sudo apt-get install python3
Still using Python 2.7? Switch now! Follow these instructions.
-
Create medusa user and group medusa. This makes sure that Medusa is isolated and is best practice for security
sudo addgroup --system medusa sudo adduser --disabled-password --system --home /var/lib/medusa --gecos "Medusa" --ingroup medusa medusa
-
Clone Medusa git repo
sudo mkdir /opt/medusa && sudo chown medusa:medusa /opt/medusa sudo git clone https://github.com/pymedusa/Medusa.git /opt/medusa sudo chown -R medusa:medusa /opt/medusa
For SysVinit Systems
-
Copy init.d service
Ubuntu:
sudo cp -v /opt/medusa/runscripts/init.ubuntu /etc/init.d/medusa
Debian:
sudo cp -v /opt/medusa/runscripts/init.debian /etc/init.d/medusa
-
Make sure your new service has correct permissions
sudo chown root:root /etc/init.d/medusa sudo chmod 644 /etc/init.d/medusa
-
Update and start your new service
sudo update-rc.d medusa defaults sudo service medusa start
For Upstart Systems
-
Copy init.d service
sudo cp -v /opt/medusa/runscripts/init.upstart /etc/init/medusa.conf
-
Make sure your new service has correct permissions
sudo chown root:root /etc/init/medusa.conf sudo chmod 644 /etc/init/medusa.conf
-
Update and start your new service
sudo service medusa start
For Systemd Systems
-
Copy systemd service
sudo cp -v /opt/medusa/runscripts/init.systemd /etc/systemd/system/medusa.service
-
Make sure your new service has correct permissions
sudo chown root:root /etc/systemd/system/medusa.service sudo chmod 644 /etc/systemd/system/medusa.service
-
Enable, start, and then check the status of your new service
sudo systemctl enable medusa sudo systemctl start medusa sudo systemctl status medusa
-
Add Medusa to startup (optional)
sudo systemctl enable medusa.service
All done, verify that Medusa is accessible at: http://your_ip:8081