Featured Post

HOWTO: MySQL install guide for NAS4Free 10.2.x

Mar 5, 2014

Setting up CouchPotato and Sickbeard on NAS4Free

The two applications I am going to place on my NAS4Free box are Couchpotato and Sickbeard.

Please note, this is for informational purposes only and I do not condone, or conduct illegal downloading.  I actually retrieved most of the information from the following site:

http://forums.nas4free.org/viewtopic.php?f=55&t=3929&p=20364&hilit=sickbeard#p20364

...but some of the steps were slightly different because I already had MySQL installed, for example.

Important Notes:
  • This was conducted on a FULL NAS4Free installation, not embedded.
  • Change /mnt/Data to your own storage location
  • Change 192.168.0.* to your NAS4Free IP address

SETTING UP FOR SICKBEARD INSTALLATION

Let's make the appropriate directory structure first:

cd /mnt/Data
mkdir Extensions
cd Extensions
mkdir var
mkdir usr
mkdir tmp

Additionally, do the following to map the var and usr directories to the /mnt/Data partition, so as not to use up space on the OS partition (specifically with logs, and cached images):

mount_unionfs -o w /mnt/Data/Extensions/var/ /var/
mount_unionfs -o w /mnt/Data/Extensions/usr/ /usr/

Also add both these lines as Command Scripts under the advanced settings, as PostInit .
Set the temporary directory for the packages, as well as the site to fetch packages from (if you are installing onto a 32 bit system change “amd64″ to “i386″):

setenv PKG_TMPDIR /mnt/Data/Extensions/tmp/
setenv PACKAGESITE "http://ftp6.us.freebsd.org/pub/FreeBSD-Archive/ports/amd64/packages-9.0-release/Latest/"

Installed the required packages for the applications to run:

pkg_add -rv python27
pkg_add -rv unzip
pkg_add -rv py27-yenc
pkg_add -rv py27-cheetah
pkg_add -rv py27-openssl
pkg_add -rv py27-feedparser
pkg_add -rv py27-utils
pkg_add -rv unrar
pkg_add -rv par2cmdline

Now install Sickbeard:

fetch "http://github.com/midgetspy/Sick-Beard/tarball/master"
tar -xzf master
rm master
mv midgetspy-Sick-Beard-fb37d33 Sickbeard
mv Sickbeard /mnt/Data/Extensions/
chmod -R 777 /mnt/Data/Extensions/Sickbeard

Test Sickbeard :
/usr/local/bin/python2.7 /mnt/Data/Extensions/Sickbeard/SickBeard.py --quiet &

Now to configure Sickbeard to startup with your NAS4Free box

CONFIGURING SICKBEARD TO STARTUP ON BOOT

cd /mnt/Data/Extensions/Sickbeard
nano sd.sh

Paste the following code into the editor that appears, replacing your IP address on the first line, your Sick beard username on the second line, and your Sick Beard password on the third line (you can create a username and password for Sick Beard from its web interface):

#!/bin/sh
fetch "http://192.168.0.4:8081/home/shutdown/ «_EOF
yoursickbeardUSERNAMEhere
yoursickbeardPASSWORDhere
_EOF

Save your changes and make that script executable by running the following command:

chmod +x sd.sh

Lastly, head back into NAS4Free's web interface, and go to System > Advanced > Command Scripts. Click the plus sign and add this as a "PostIinit" command:

/usr/local/bin/python2.7 /mnt/Data/Extensions/Sickbeard/SickBeard.py --quiet &

Add the following command as a "Shutdown" command as well:

/mnt/Data/Extensions/Sickbeard/sd.sh

Remember, as you set up Sick Beard, to use absolute file paths in all the settings e.g.

/mnt/Data/Downloads/Complete

SETTING UP FOR COUCHPOTATO INSTALLATION

cd /mnt/Data/Extensions/tmp
fetch "https://github.com/RuudBurger/CouchPotatoServer/tarball/master"
tar -xzf master
rm master
mv RuudBurger* CouchPotato
mv /mnt/Data/Extensions/tmp/CouchPotato /mnt/Data/Extensions/CouchPotato

Test CouchPotato
/usr/local/bin/python2.7 /mnt/Data/Extensions/CouchPotato/CouchPotato.py --quiet &


CONFIGURING COUCHPOTATO TO STARTUP ON BOOT

Head back into NAS4Free's web interface, and go to System > Advanced > Command Scripts. Click the plus sign and add this as a "PostIinit" command:

/usr/local/bin/python2.7 /mnt/Data/Extensions/CouchPotato/CouchPotato.py --quiet &

Remember, as you set up CouchPotato, to use absolute file paths in all the settings e.g.

/mnt/Data/Downloads/Complete


Post a Comment