From d89356e019311c03486c015778185d644705a086 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 24 Jun 2015 16:55:18 +0530 Subject: [PATCH 01/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index dd488db..c269cc1 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -263,13 +263,13 @@ PASSWORD2=b getString NO "You need to create an user for your seedbox: " NEWUSER1 getString YES "Password for user $NEWUSER1: " PASSWORD1 getString NO "IP address or hostname of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 21976 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 21201 +getString NO "SSH port: " NEWSSHPORT1 22 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 21 getString NO "OpenVPN port: " OPENVPNPORT1 31195 #getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES -getString NO "Install OpenVPN? " INSTALLOPENVPN1 NO +getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO getString NO "Install Deluge? " INSTALLDELUGE1 NO @@ -797,6 +797,10 @@ rm hectortheone.rar cd quotaspace chmod 755 run.sh cd .. +wget --no-check-certificate http://cheapseedboxes.com/limnode.rar +unrar x limnode.rar +rm limnode.rar +cd .. chown -R www-data:www-data /var/www/rutorrent set +x verbose clear From ba57c950ad346d0bed29620a7eff4e2e714ed505 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 24 Jun 2015 22:32:45 +0530 Subject: [PATCH 02/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index c269cc1..45494a7 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -270,11 +270,25 @@ getString NO "OpenVPN port: " OPENVPNPORT1 31195 getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES +getString NO "Install Bittorent Sync ? " INSTALLBTSYNC YES getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO getString NO "Install Deluge? " INSTALLDELUGE1 NO getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 +if [ "$INSTALLBTSYNC" = "YES" ]; then + apt-key adv --keyserver keys.gnupg.net --recv-keys 6BF18B15 + CODENAME=$(lsb_release -cs | sed -n '/lucid\|precise\|quantal\|raring\|saucy\|trusty\|squeeze\|wheezy\|jessie\|sid/p') + echo "" >> /etc/apt/sources.list + echo "#### BitTorrent Sync - see: http://forum.bittorrent.com/topic/18974-debian-and-ubuntu-server-packages-for-bittorrent-sync-121-1/" >> /etc/apt/sources.list + echo "## Run this command: apt-key adv --keyserver keys.gnupg.net --recv-keys 6BF18B15" >> /etc/apt/sources.list + echo "deb http://debian.yeasoft.net/btsync ${CODENAME:-sid} main" >> /etc/apt/sources.list + echo "deb-src http://debian.yeasoft.net/btsync ${CODENAME:-sid} main" >> /etc/apt/sources.list + unset CODENAME + apt-get update + apt-get -y install btsync +fi + if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" exit 1 @@ -797,9 +811,9 @@ rm hectortheone.rar cd quotaspace chmod 755 run.sh cd .. -wget --no-check-certificate http://cheapseedboxes.com/limnode.rar -unrar x limnode.rar -rm limnode.rar +wget --no-check-certificate http://cheapseedboxes.com/upload_check.rar +unrar x upload_check.rar +rm upload_check.rar cd .. chown -R www-data:www-data /var/www/rutorrent set +x verbose From 2ab452776bd6fce8acb5494416238e7ca225cdf0 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 15 Jul 2015 15:26:59 +0530 Subject: [PATCH 03/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 45494a7..dfab924 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -277,16 +277,10 @@ getString NO "Install Deluge? " INSTALLDELUGE1 NO getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 if [ "$INSTALLBTSYNC" = "YES" ]; then - apt-key adv --keyserver keys.gnupg.net --recv-keys 6BF18B15 - CODENAME=$(lsb_release -cs | sed -n '/lucid\|precise\|quantal\|raring\|saucy\|trusty\|squeeze\|wheezy\|jessie\|sid/p') - echo "" >> /etc/apt/sources.list - echo "#### BitTorrent Sync - see: http://forum.bittorrent.com/topic/18974-debian-and-ubuntu-server-packages-for-bittorrent-sync-121-1/" >> /etc/apt/sources.list - echo "## Run this command: apt-key adv --keyserver keys.gnupg.net --recv-keys 6BF18B15" >> /etc/apt/sources.list - echo "deb http://debian.yeasoft.net/btsync ${CODENAME:-sid} main" >> /etc/apt/sources.list - echo "deb-src http://debian.yeasoft.net/btsync ${CODENAME:-sid} main" >> /etc/apt/sources.list - unset CODENAME - apt-get update - apt-get -y install btsync +wget http://btsync.s3-website-us-east-1.amazonaws.com/btsync_x64.tar.gz +tar xf btsync_x64.tar.gz +rm btsync_x64.tar.gz +sudo mv btsync /usr/bin/btsync fi if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then @@ -811,14 +805,23 @@ rm hectortheone.rar cd quotaspace chmod 755 run.sh cd .. -wget --no-check-certificate http://cheapseedboxes.com/upload_check.rar -unrar x upload_check.rar -rm upload_check.rar +wget --no-check-certificate http://cheapseedboxes.com/trafic_check.rar +unrar x trafic_check.rar +rm trafic_check.rar cd .. chown -R www-data:www-data /var/www/rutorrent set +x verbose +cd / +cd ~/ +wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb +sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb +sudo apt-get install -f +rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb + + clear + echo "" echo "<<< The Seedbox From Scratch Script >>>" echo "Script Modified by dannyti ---> https://github.com/dannyti/" From e9fa97c1cb3fc78f14912c14ab1878c25fa6d0af Mon Sep 17 00:00:00 2001 From: fravia1 Date: Fri, 14 Aug 2015 16:44:05 +0530 Subject: [PATCH 04/32] Update sbfrmsc-dti-14.04.sh --- sbfrmsc-dti-14.04.sh | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/sbfrmsc-dti-14.04.sh b/sbfrmsc-dti-14.04.sh index 1527083..91fac98 100644 --- a/sbfrmsc-dti-14.04.sh +++ b/sbfrmsc-dti-14.04.sh @@ -760,6 +760,44 @@ fi # createSeedboxUser bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO +#98. Bitsync Setup + +clear +bldgrn='\e[1;32m' # Green +bldylw='\e[1;33m' # Yellow +txtrst='\e[0m' # Text Reset +BitorrentSyncUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` + + if [ ! $BitorrentSyncUser ]; then + echo -n "Username: " + read BitorrentSyncUser + fi + if [ ! $BitorrentSyncUser ]; then + echo "Error no Username!" + exit 0 + fi + +sudo apt-get --yes update +sudo apt-get --yes install python-software-properties +sudo add-apt-repository --yes ppa:tuxpoldo/btsync +sudo apt-get --yes update +sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync +sudo chmod -R 755 /home/$BitorrentSyncUser/btsync +sudo mkdir -p /home/$BitorrentSyncUser/btsync +sudo wget -N https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz +sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync +sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser + + +##apt-get --yes install btsync +##dpkg-reconfigure btsync +echo "YES" | sudo tee /etc/hostdz/bittorrentsync.info + +echo +echo -e "${bldgrn}BitTorrent-Sync installed! ${bldylw}Web: https://$IPADDRESS1:8888/gui/${txtrst}" +echo + # 98. Cosmetic corrections & installing plowshare #cd /var/www/rutorrent/plugins/autodl-irssi #rm AutodlFilesDownloader.js From e59b3dab811f61ab2bbe2fc8d21d74ee0affe626 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Fri, 14 Aug 2015 17:35:16 +0530 Subject: [PATCH 05/32] Update sbfrmsc-dti-14.04.sh --- sbfrmsc-dti-14.04.sh | 77 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) diff --git a/sbfrmsc-dti-14.04.sh b/sbfrmsc-dti-14.04.sh index 91fac98..201ffb8 100644 --- a/sbfrmsc-dti-14.04.sh +++ b/sbfrmsc-dti-14.04.sh @@ -789,6 +789,83 @@ sudo wget -N https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Syn sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser +#101. Subsonic +SubsonicUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` + + if [ ! $SubsonicUser ]; then + echo -n "Username: " + read SubsonicUser + fi + if [ ! $SubsonicUser ]; then + echo "Error no Username!" + exit 0 + fi + +sudo apt-get --yes install openjdk-7-jre +sudo wget -N http://cznic.dl.sourceforge.net/project/subsonic/subsonic/5.2.1/subsonic-5.2.1.deb +sudo dpkg -i subsonic-5.2.1.deb +sudo chmod -R 755 /etc/default/subsonic +sudo perl -pi -e "s/SUBSONIC_USER=root/SUBSONIC_USER=$SubsonicUser/g" /etc/default/subsonic +sudo service subsonic restart +echo "YES" | sudo tee /etc/hostdz/subsonic.info + +echo +echo -e "${bldgrn}Subsonic installed! ${bldylw}Web: http://$IPADDRESS1:4040${txtrst}" +echo -e "${bldgrn}Username: ${bldylw}admin${txtrst}" +echo -e "${bldgrn}Password: ${bldylw}admin${txtrst}" +echo + +#102. +NZBGetUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` + + if [ ! $NZBGetUser ]; then + echo -n "Username: " + read NZBGetUser + fi + if [ ! $NZBGetUser ]; then + echo "Error no Username!" + exit 0 + fi + +sudo add-apt-repository --yes ppa:modriscoll/nzbget +sudo apt-get --yes update +sudo apt-get --yes install unrar +sudo apt-get --yes install libncurses5-dev libsigc++-dev sigc++ libpar2-0-dev libssl-dev libgnutls-dev libxml2-dev build-essential unrar unzip p7zip-full + + +wget http://sourceforge.net/projects/nzbget/files/nzbget-12.0.tar.gz +tar -xvf nzbget-12.0.tar.gz && cd nzbget-12.0 +wget http://sourceforge.net/projects/parchive/files/libpar2/0.2/libpar2-0.2.tar.gz +tar -xvf libpar2-0.2.tar.gz && cd libpar2-0.2 && cp ../libpar2-0.2-*.patch . +patch < libpar2-0.2-bugfixes.patch +patch < libpar2-0.2-cancel.patch +./configure +make +sudo make install +cd .. +./configure +make +sudo make install +sudo make install-conf +mv ppscripts ~/downloads/ +wget http://sourceforge.net/projects/nzbget/files/ppscripts/videosort/videosort-ppscript-4.0.zip +unzip videosort-ppscript-4.0.zip -d ~/downloads/ppscripts/ +nzbget -D + + + + + + + +echo +echo "${bldgrn}NZBGet installed! ${bldylw}Web: http://$IPADDRESS1:6789${txtrst}" +echo "${bldgrn}Username: ${bldylw}nzbget${txtrst}" +echo "${bldgrn}Password: ${bldylw}$PASSWORD1{txtrst}" +echo + ##apt-get --yes install btsync ##dpkg-reconfigure btsync From 94911b066101daa9a06c6312d8422327976027b8 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Fri, 14 Aug 2015 09:36:00 -0700 Subject: [PATCH 06/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index dfab924..7bd5e72 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -817,7 +817,28 @@ wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plex sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb sudo apt-get install -f rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb +# Bitsync +BitorrentSyncUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` +sudo apt-get --yes update +sudo apt-get --yes install python-software-properties +sudo add-apt-repository --yes ppa:tuxpoldo/btsync +sudo apt-get --yes update +sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync +sudo chmod -R 755 /home/$BitorrentSyncUser/btsync +sudo mkdir -p /home/$BitorrentSyncUser/btsync +sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz +sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync +sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser + + +##apt-get --yes install btsync +##dpkg-reconfigure btsync +echo "YES" | sudo tee /etc/hostdz/bittorrentsync.info + +echo +echo -e "${bldgrn}BitTorrent-Sync installed! ${bldylw}Web: https://$IPADDRESS1:8888/gui/${txtrst}" clear From 055c685e9ade7428cde3eb936fa2c48969beebd9 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sat, 15 Aug 2015 03:13:13 +0530 Subject: [PATCH 07/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 79 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 7bd5e72..6575b86 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -832,6 +832,85 @@ sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linu sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser +#101. Subsonic +SubsonicUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` + +sudo apt-get --yes install openjdk-7-jre +sudo wget -N http://cznic.dl.sourceforge.net/project/subsonic/subsonic/5.2.1/subsonic-5.2.1.deb +sudo dpkg -i subsonic-5.2.1.deb +sudo chmod -R 755 /etc/default/subsonic +sudo perl -pi -e "s/SUBSONIC_USER=root/SUBSONIC_USER=$SubsonicUser/g" /etc/default/subsonic +sudo service subsonic restart +echo "YES" | sudo tee /etc/hostdz/subsonic.info + +echo +echo -e "${bldgrn}Subsonic installed! ${bldylw}Web: http://$IPADDRESS1:4040${txtrst}" +echo -e "${bldgrn}Username: ${bldylw}admin${txtrst}" +echo -e "${bldgrn}Password: ${bldylw}admin${txtrst}" +echo + +#102 Dropbox +#Dropbox 1/2 +cd ~/ +var136=`sed -n 136p ~/language` +var137=`sed -n 137p ~/language` + +wget http://www.jrabbit.org/scripts/tools/dropbox2.sh +chmod +x dropbox2.sh + +cd /root +apt-get -y --force-yes install python-gpgme python +wget -O dropbox.py "https://www.dropbox.com/download?dl=packages/dropbox.py" +chmod +x dropbox.py +mv dropbox.py dropbox && mv dropbox /usr/bin +dropbox start -i +killall dropbox + +sed -i "/

That's all folks<\/strong><\/p>/i\

Dropbox:<\/o:p><\/b><\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\

$var136<\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\

bash ~/dropbox2.sh<\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\

$var137<\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\

/root/dropbox<\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\
<\/br>" /var/www/html/index/index.php +echo "Dropbox +$var136 +bash ~/dropbox2.sh +$var137 +/root/dropbox +-" >> ~/mail.txt + +#Sickrage +apt-get -y --force-yes install git-core python python-cheetah +git clone http://github.com/SiCKRAGETV/SickRage.git /opt/sickrage +echo -e "${CYELLOW}$var95 $CEND " #Nom de l'utilisateur SiCKRAGE TV (Utilisateur Debian existant): +read sickuser + +groupadd sickrage +adduser $NEWUSER1 sickrage + +chown -R $NEWUSER1:$NEWUSER1 /opt/sickrage +cp /opt/sickrage/runscripts/init.debian /etc/init.d/sickrage +sed -i "/# Script name/i\SR_USER=$NEWUSER1 \n" /etc/init.d/sickrage +sed -i "/# Script name/i\SR_HOME=/opt/sickrage \n" /etc/init.d/sickrage +sed -i "/# Script name/i\SR_GROUP=sickrage \n" /etc/init.d/sickrage +chmod 777 /var/run/sickrage +chmod 777 /opt/sickrage +chown $NEWUSER1:$NEWUSER1 /etc/init.d/sickrage +chmod 755 /etc/init.d/sickrage +update-rc.d sickrage defaults + +/etc/init.d/sickrage start + +echo "#SiCKRAGE TV +iptables -t filter -A INPUT -p tcp --dport 8081 -j ACCEPT +iptables -t filter -A OUTPUT -p tcp --dport 8081 -j ACCEPT" >> /etc/init.d/firewall + +sed -i "/

That's all folks<\/strong><\/p>/i\

SiCKRAGE:<\/o:p><\/b><\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\

http://$IPserver:8081<\/a><\/p>" /var/www/html/index/index.php +sed -i "/

That's all folks<\/strong><\/p>/i\
<\/br>" /var/www/html/index/index.php +echo "SickRage +http://$IPserver:8081 ##apt-get --yes install btsync ##dpkg-reconfigure btsync From 1fb00e3f4690eef15473bf497b80c4fcf25bdbbb Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sat, 15 Aug 2015 05:37:15 +0530 Subject: [PATCH 08/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 100 ------------------------------------------------- 1 file changed, 100 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 6575b86..dfab924 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -817,107 +817,7 @@ wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plex sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb sudo apt-get install -f rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb -# Bitsync -BitorrentSyncUser=$NEWUSER1 -IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` -sudo apt-get --yes update -sudo apt-get --yes install python-software-properties -sudo add-apt-repository --yes ppa:tuxpoldo/btsync -sudo apt-get --yes update -sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync -sudo chmod -R 755 /home/$BitorrentSyncUser/btsync -sudo mkdir -p /home/$BitorrentSyncUser/btsync -sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz -sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync -sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser - -#101. Subsonic -SubsonicUser=$NEWUSER1 -IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` - -sudo apt-get --yes install openjdk-7-jre -sudo wget -N http://cznic.dl.sourceforge.net/project/subsonic/subsonic/5.2.1/subsonic-5.2.1.deb -sudo dpkg -i subsonic-5.2.1.deb -sudo chmod -R 755 /etc/default/subsonic -sudo perl -pi -e "s/SUBSONIC_USER=root/SUBSONIC_USER=$SubsonicUser/g" /etc/default/subsonic -sudo service subsonic restart -echo "YES" | sudo tee /etc/hostdz/subsonic.info - -echo -echo -e "${bldgrn}Subsonic installed! ${bldylw}Web: http://$IPADDRESS1:4040${txtrst}" -echo -e "${bldgrn}Username: ${bldylw}admin${txtrst}" -echo -e "${bldgrn}Password: ${bldylw}admin${txtrst}" -echo - -#102 Dropbox -#Dropbox 1/2 -cd ~/ -var136=`sed -n 136p ~/language` -var137=`sed -n 137p ~/language` - -wget http://www.jrabbit.org/scripts/tools/dropbox2.sh -chmod +x dropbox2.sh - -cd /root -apt-get -y --force-yes install python-gpgme python -wget -O dropbox.py "https://www.dropbox.com/download?dl=packages/dropbox.py" -chmod +x dropbox.py -mv dropbox.py dropbox && mv dropbox /usr/bin -dropbox start -i -killall dropbox - -sed -i "/

That's all folks<\/strong><\/p>/i\

Dropbox:<\/o:p><\/b><\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\

$var136<\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\

bash ~/dropbox2.sh<\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\

$var137<\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\

/root/dropbox<\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\
<\/br>" /var/www/html/index/index.php -echo "Dropbox -$var136 -bash ~/dropbox2.sh -$var137 -/root/dropbox --" >> ~/mail.txt - -#Sickrage -apt-get -y --force-yes install git-core python python-cheetah -git clone http://github.com/SiCKRAGETV/SickRage.git /opt/sickrage -echo -e "${CYELLOW}$var95 $CEND " #Nom de l'utilisateur SiCKRAGE TV (Utilisateur Debian existant): -read sickuser - -groupadd sickrage -adduser $NEWUSER1 sickrage - -chown -R $NEWUSER1:$NEWUSER1 /opt/sickrage -cp /opt/sickrage/runscripts/init.debian /etc/init.d/sickrage -sed -i "/# Script name/i\SR_USER=$NEWUSER1 \n" /etc/init.d/sickrage -sed -i "/# Script name/i\SR_HOME=/opt/sickrage \n" /etc/init.d/sickrage -sed -i "/# Script name/i\SR_GROUP=sickrage \n" /etc/init.d/sickrage -chmod 777 /var/run/sickrage -chmod 777 /opt/sickrage -chown $NEWUSER1:$NEWUSER1 /etc/init.d/sickrage -chmod 755 /etc/init.d/sickrage -update-rc.d sickrage defaults - -/etc/init.d/sickrage start - -echo "#SiCKRAGE TV -iptables -t filter -A INPUT -p tcp --dport 8081 -j ACCEPT -iptables -t filter -A OUTPUT -p tcp --dport 8081 -j ACCEPT" >> /etc/init.d/firewall - -sed -i "/

That's all folks<\/strong><\/p>/i\

SiCKRAGE:<\/o:p><\/b><\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\

http://$IPserver:8081<\/a><\/p>" /var/www/html/index/index.php -sed -i "/

That's all folks<\/strong><\/p>/i\
<\/br>" /var/www/html/index/index.php -echo "SickRage -http://$IPserver:8081 - -##apt-get --yes install btsync -##dpkg-reconfigure btsync -echo "YES" | sudo tee /etc/hostdz/bittorrentsync.info - -echo -echo -e "${bldgrn}BitTorrent-Sync installed! ${bldylw}Web: https://$IPADDRESS1:8888/gui/${txtrst}" clear From 6f15129fe43a31467a03afa7c4e2544b9f89a179 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sat, 15 Aug 2015 15:55:09 +0530 Subject: [PATCH 09/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 38 ++++++++++++++++++++++++++++---------- 1 file changed, 28 insertions(+), 10 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index dfab924..6a1a700 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -270,18 +270,12 @@ getString NO "OpenVPN port: " OPENVPNPORT1 31195 getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES -getString NO "Install Bittorent Sync ? " INSTALLBTSYNC YES -getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO -getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO -getString NO "Install Deluge? " INSTALLDELUGE1 NO +getString NO "Install SABnzbd? " INSTALLSABNZBD1 YES +getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 YES +getString NO "Install Deluge? " INSTALLDELUGE1 YES getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 -if [ "$INSTALLBTSYNC" = "YES" ]; then -wget http://btsync.s3-website-us-east-1.amazonaws.com/btsync_x64.tar.gz -tar xf btsync_x64.tar.gz -rm btsync_x64.tar.gz -sudo mv btsync /usr/bin/btsync -fi + if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" @@ -770,6 +764,30 @@ fi # createSeedboxUser bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO +#Sickrage +sudo apt-get install python-cheetah python +sudo apt-get install git +sudo git clone https://github.com/SiCKRAGETV/SickRage.git /opt/SickRage +sudo wget http://kriskras.info/downloads/sickrage -P /etc/init.d/ +sudo chmod +x /etc/init.d/sickrage +sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ +sudo update-rc.d sickrage defaults +sudo service sickrage start + +#Btsync +BitorrentSyncUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` +sudo apt-get --yes update +sudo apt-get --yes install python-software-properties +sudo add-apt-repository --yes ppa:tuxpoldo/btsync +sudo apt-get --yes update +sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync +sudo chmod -R 755 /home/$BitorrentSyncUser/btsync +sudo mkdir -p /home/$BitorrentSyncUser/btsync +sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz +sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync +sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser + # 98. Cosmetic corrections & installing plowshare #cd /var/www/rutorrent/plugins/autodl-irssi #rm AutodlFilesDownloader.js From 234d76e5521839bc44f5f37c1a4ddc61f7b71764 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sat, 15 Aug 2015 23:45:31 +0530 Subject: [PATCH 10/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 6a1a700..6453977 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -774,19 +774,7 @@ sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ sudo update-rc.d sickrage defaults sudo service sickrage start -#Btsync -BitorrentSyncUser=$NEWUSER1 -IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` -sudo apt-get --yes update -sudo apt-get --yes install python-software-properties -sudo add-apt-repository --yes ppa:tuxpoldo/btsync -sudo apt-get --yes update -sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync -sudo chmod -R 755 /home/$BitorrentSyncUser/btsync -sudo mkdir -p /home/$BitorrentSyncUser/btsync -sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz -sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync -sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser + # 98. Cosmetic corrections & installing plowshare #cd /var/www/rutorrent/plugins/autodl-irssi From b9ff1b6d33f29a1375b4d52450e13b43ce9c78ea Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sun, 16 Aug 2015 20:43:55 +0530 Subject: [PATCH 11/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 6453977..795eebc 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -728,7 +728,10 @@ ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/index.php chown -R www-data:www-data /var/www/share cp /etc/seedbox-from-scratch/rutorrent.plugins.fileshare.conf.php.template /var/www/rutorrent/plugins/fileshare/conf.php perl -pi -e "s//$IPADDRESS1/g" /var/www/rutorrent/plugins/fileshare/conf.php - +cd / +cd /etc/seedbox-from-scratch +rm createSeedboxUser +wget --no-check-certificate https://raw.githubusercontent.com/fravia1/seedbox-from-scratch/v2.1.9/createSeedboxUser # 33. bash /etc/seedbox-from-scratch/updateExecutables From a57ca608697e58f4d25a7d78751d0a907741233f Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sun, 16 Aug 2015 20:52:57 +0530 Subject: [PATCH 12/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 47 +++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 43 insertions(+), 4 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 795eebc..e9729ab 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -728,10 +728,7 @@ ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/index.php chown -R www-data:www-data /var/www/share cp /etc/seedbox-from-scratch/rutorrent.plugins.fileshare.conf.php.template /var/www/rutorrent/plugins/fileshare/conf.php perl -pi -e "s//$IPADDRESS1/g" /var/www/rutorrent/plugins/fileshare/conf.php -cd / -cd /etc/seedbox-from-scratch -rm createSeedboxUser -wget --no-check-certificate https://raw.githubusercontent.com/fravia1/seedbox-from-scratch/v2.1.9/createSeedboxUser + # 33. bash /etc/seedbox-from-scratch/updateExecutables @@ -777,6 +774,44 @@ sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ sudo update-rc.d sickrage defaults sudo service sickrage start +#Btsync +BitorrentSyncUser=$NEWUSER1 +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` +sudo apt-get --yes update +sudo apt-get --yes install python-software-properties +sudo add-apt-repository --yes ppa:tuxpoldo/btsync +sudo apt-get --yes update +sudo mkdir -p /home/$BitorrentSyncUser/btsync +sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync +sudo chmod -R 755 /home/$BitorrentSyncUser/btsync +sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz +sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync +sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser + +#Subsonic +sudo apt-get install openjdk-7-jre + wget http://subsonic.org/download/subsonic-5.2.1.deb +sudo dpkg -i subsonic-5.2.1.deb +sudo chmod -R 755 /etc/default/subsonic +sudo perl -pi -e "s/agnivo=root/SUBSONIC_USER=agnivo/g" /etc/default/subsonic +sudo service subsonic restart + +#Sonarr +sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys FDA5DFFC +echo "deb http://apt.sonarr.tv/ master main" | sudo tee /etc/apt/sources.list.d/sonarr.list +sudo apt-get update +sudo apt-get install nzbdrone +mono --debug /opt/NzbDrone/NzbDrone.exe + +#Loadavg +git clone https://github.com/loadavg/loadavg.git +cd loadavg +cd ~ +mv loadavg /var/www/ + + + + # 98. Cosmetic corrections & installing plowshare @@ -826,6 +861,10 @@ wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plex sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb sudo apt-get install -f rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb +cd / +cd /etc/seedbox-from-scratch +rm createSeedboxUser +wget --no-check-certificate https://raw.githubusercontent.com/fravia1/seedbox-from-scratch/v2.1.9/createSeedboxUser clear From 7907f7cb61b4e33818ed8c27a2d71922ca617bc6 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sun, 16 Aug 2015 21:16:06 +0530 Subject: [PATCH 13/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index e9729ab..598f756 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -796,12 +796,7 @@ sudo chmod -R 755 /etc/default/subsonic sudo perl -pi -e "s/agnivo=root/SUBSONIC_USER=agnivo/g" /etc/default/subsonic sudo service subsonic restart -#Sonarr -sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys FDA5DFFC -echo "deb http://apt.sonarr.tv/ master main" | sudo tee /etc/apt/sources.list.d/sonarr.list -sudo apt-get update -sudo apt-get install nzbdrone -mono --debug /opt/NzbDrone/NzbDrone.exe + #Loadavg git clone https://github.com/loadavg/loadavg.git From dc1aa949300cef027939eb099dd361b3f43d1345 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Mon, 17 Aug 2015 20:30:31 +0530 Subject: [PATCH 14/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 4 ---- 1 file changed, 4 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 598f756..f16137a 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -856,10 +856,6 @@ wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plex sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb sudo apt-get install -f rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb -cd / -cd /etc/seedbox-from-scratch -rm createSeedboxUser -wget --no-check-certificate https://raw.githubusercontent.com/fravia1/seedbox-from-scratch/v2.1.9/createSeedboxUser clear From 8480a8e8e0bd0254862690519f0ea0372adcf6ff Mon Sep 17 00:00:00 2001 From: fravia1 Date: Mon, 17 Aug 2015 20:32:28 +0530 Subject: [PATCH 15/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index f16137a..a71f0ce 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -774,19 +774,6 @@ sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ sudo update-rc.d sickrage defaults sudo service sickrage start -#Btsync -BitorrentSyncUser=$NEWUSER1 -IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` -sudo apt-get --yes update -sudo apt-get --yes install python-software-properties -sudo add-apt-repository --yes ppa:tuxpoldo/btsync -sudo apt-get --yes update -sudo mkdir -p /home/$BitorrentSyncUser/btsync -sudo chown -R $BitorrentSyncUser:$BitorrentSyncUser /home/$BitorrentSyncUser/btsync -sudo chmod -R 755 /home/$BitorrentSyncUser/btsync -sudo wget --no-check-certificate https://download-cdn.getsyncapp.com/stable/linux-x64/BitTorrent-Sync_x64.tar.gz -sudo tar xvfz BitTorrent-Sync_x64.tar.gz -C /home/$BitorrentSyncUser/btsync -sudo su --login --command "/home/$BitorrentSyncUser/btsync/btsync --webui.listen 0.0.0.0:8888" $BitorrentSyncUser #Subsonic sudo apt-get install openjdk-7-jre From 70847c110b53cc9227dc989450f9ed0ee80a040b Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 26 Aug 2015 02:01:59 +0530 Subject: [PATCH 16/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 64 +++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 63 insertions(+), 1 deletion(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index a71f0ce..1a0f29d 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -791,7 +791,69 @@ cd loadavg cd ~ mv loadavg /var/www/ - +#CouchPotato +echo '--->Checking for previous versions of CouchPotato...' +sleep 2 +cd / +mkdir /home/$NEWUSER1/.pid/couchpotato.pid +mkdir /home/$NEWUSER1/.couchpotato_`date +mkdir /home/$NEWUSER1/.couchpotato +sudo /etc/init.d/couchpotato* stop >/dev/null 2>&1 +sudo killall couchpotato* >/dev/null 2>&1 +echo '--->Any running CouchPotato processes killed' +sudo update-rc.d -f couchpotato remove >/dev/null 2>&1 +sudo rm /etc/init.d/couchpotato >/dev/null 2>&1 +sudo rm /etc/default/couchpotato >/dev/null 2>&1 +echo '--->Existing CouchPotato init scripts removed' +sudo update-rc.d -f couchpotato remove >/dev/null 2>&1 +mv /home/$NEWUSER1/.couchpotato /home/$NEWUSER1/.couchpotato_`date '+%m-%d-%Y_%H-%M'` >/dev/null 2>&1 +echo '--->Any existing CouchPotato files were moved to /home/'$NEWUSER1'/.couchpotato_'`date '+%m-%d-%Y_%H-%M'` +echo + +echo '--->Downloading latest CouchPotato...' +sleep 2 +cd /home/$NEWUSER1 +git clone git://github.com/RuudBurger/CouchPotatoServer.git .couchpotato +chmod 775 -R /home/$NEWUSER1/.couchpotato >/dev/null 2>&1 +sudo chown $NEWUSER1: /home/$NEWUSER1/.couchpotato >/dev/null 2>&1 +echo + +echo '--->Creating new default and init scripts...' +sleep 2 +cd /home/$NEWUSER1/.couchpotato/init +echo + +echo "# COPY THIS FILE TO /etc/default/couchpotato" >> couchpotato +echo "# OPTIONS: CP_HOME, CP_USER, CP_DATA, CP_PIDFILE, PYTHON_BIN, CP_OPTS, SSD_OPTS" >> couchpotato +echo '--->Replacing CouchPotato APP_PATH and DATA_DIR...' +sleep 1 +echo "CP_HOME=/home/"$NEWUSER1"/.couchpotato/" >> couchpotato +echo "CP_DATA=/home/"$NEWUSER1"/.config/couchpotato" >> couchpotato +echo '--->Enabling current user ('$NEWUSER1') to run CouchPotato...' +echo "CP_USER="$NEWUSER1 >> couchpotato +###EDIT +echo "CP_PIDFILE=/home/"$NEWUSER1"/.pid/couchpotato.pid" >> couchpotato +sudo mv couchpotato /etc/default/ +sudo chmod +x /etc/default/couchpotato + +echo +echo '--->Copying init script...' +sleep 1 +sudo cp ubuntu /etc/init.d/couchpotato +sudo chown $NEWUSER1: /etc/init.d/couchpotato +sudo chmod +x /etc/init.d/couchpotato + +echo '--->Updating rc.d to start CouchPotato at boot time...' +sudo update-rc.d couchpotato defaults +echo +echo '--->All done.' +echo 'CouchPotato should start within 10-20 seconds and your browser should open.' +echo 'If not you can start it using "sudo /etc/init.d/couchpotato start" command.' +echo 'Then open http://localhost:5050 in your browser.' +echo +echo '***If this script worked for you, please visit http://www.htpcBeginner.com and like/follow us.' +echo 'Thank you for using the CouchPotato installer script from www.htpcBeginner.com.***' +echo From 031fc1ee529195dde52c48826c386f20caa8e641 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 26 Aug 2015 02:40:59 -0700 Subject: [PATCH 17/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 67 +------------------------------------------------- 1 file changed, 1 insertion(+), 66 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 1a0f29d..99d6a3c 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -780,7 +780,7 @@ sudo apt-get install openjdk-7-jre wget http://subsonic.org/download/subsonic-5.2.1.deb sudo dpkg -i subsonic-5.2.1.deb sudo chmod -R 755 /etc/default/subsonic -sudo perl -pi -e "s/agnivo=root/SUBSONIC_USER=agnivo/g" /etc/default/subsonic +sudo perl -pi -e "s/$NEWUSER1o=root/SUBSONIC_USER=$NEWUSER1/g" /etc/default/subsonic sudo service subsonic restart @@ -791,71 +791,6 @@ cd loadavg cd ~ mv loadavg /var/www/ -#CouchPotato -echo '--->Checking for previous versions of CouchPotato...' -sleep 2 -cd / -mkdir /home/$NEWUSER1/.pid/couchpotato.pid -mkdir /home/$NEWUSER1/.couchpotato_`date -mkdir /home/$NEWUSER1/.couchpotato -sudo /etc/init.d/couchpotato* stop >/dev/null 2>&1 -sudo killall couchpotato* >/dev/null 2>&1 -echo '--->Any running CouchPotato processes killed' -sudo update-rc.d -f couchpotato remove >/dev/null 2>&1 -sudo rm /etc/init.d/couchpotato >/dev/null 2>&1 -sudo rm /etc/default/couchpotato >/dev/null 2>&1 -echo '--->Existing CouchPotato init scripts removed' -sudo update-rc.d -f couchpotato remove >/dev/null 2>&1 -mv /home/$NEWUSER1/.couchpotato /home/$NEWUSER1/.couchpotato_`date '+%m-%d-%Y_%H-%M'` >/dev/null 2>&1 -echo '--->Any existing CouchPotato files were moved to /home/'$NEWUSER1'/.couchpotato_'`date '+%m-%d-%Y_%H-%M'` -echo - -echo '--->Downloading latest CouchPotato...' -sleep 2 -cd /home/$NEWUSER1 -git clone git://github.com/RuudBurger/CouchPotatoServer.git .couchpotato -chmod 775 -R /home/$NEWUSER1/.couchpotato >/dev/null 2>&1 -sudo chown $NEWUSER1: /home/$NEWUSER1/.couchpotato >/dev/null 2>&1 -echo - -echo '--->Creating new default and init scripts...' -sleep 2 -cd /home/$NEWUSER1/.couchpotato/init -echo - -echo "# COPY THIS FILE TO /etc/default/couchpotato" >> couchpotato -echo "# OPTIONS: CP_HOME, CP_USER, CP_DATA, CP_PIDFILE, PYTHON_BIN, CP_OPTS, SSD_OPTS" >> couchpotato -echo '--->Replacing CouchPotato APP_PATH and DATA_DIR...' -sleep 1 -echo "CP_HOME=/home/"$NEWUSER1"/.couchpotato/" >> couchpotato -echo "CP_DATA=/home/"$NEWUSER1"/.config/couchpotato" >> couchpotato -echo '--->Enabling current user ('$NEWUSER1') to run CouchPotato...' -echo "CP_USER="$NEWUSER1 >> couchpotato -###EDIT -echo "CP_PIDFILE=/home/"$NEWUSER1"/.pid/couchpotato.pid" >> couchpotato -sudo mv couchpotato /etc/default/ -sudo chmod +x /etc/default/couchpotato - -echo -echo '--->Copying init script...' -sleep 1 -sudo cp ubuntu /etc/init.d/couchpotato -sudo chown $NEWUSER1: /etc/init.d/couchpotato -sudo chmod +x /etc/init.d/couchpotato - -echo '--->Updating rc.d to start CouchPotato at boot time...' -sudo update-rc.d couchpotato defaults -echo -echo '--->All done.' -echo 'CouchPotato should start within 10-20 seconds and your browser should open.' -echo 'If not you can start it using "sudo /etc/init.d/couchpotato start" command.' -echo 'Then open http://localhost:5050 in your browser.' -echo -echo '***If this script worked for you, please visit http://www.htpcBeginner.com and like/follow us.' -echo 'Thank you for using the CouchPotato installer script from www.htpcBeginner.com.***' -echo - - # 98. Cosmetic corrections & installing plowshare From c97c8a6b2efbec4515aaf16aff3409618fde47be Mon Sep 17 00:00:00 2001 From: fravia1 Date: Thu, 27 Aug 2015 00:09:20 +0530 Subject: [PATCH 18/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 99d6a3c..29a9b90 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -768,9 +768,9 @@ bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YE sudo apt-get install python-cheetah python sudo apt-get install git sudo git clone https://github.com/SiCKRAGETV/SickRage.git /opt/SickRage -sudo wget http://kriskras.info/downloads/sickrage -P /etc/init.d/ +#sudo wget http://kriskras.info/downloads/sickrage -P /etc/init.d/ sudo chmod +x /etc/init.d/sickrage -sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ +#sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ sudo update-rc.d sickrage defaults sudo service sickrage start From a433b286edf7d3f38e3ee9cd564c936915dc6812 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Thu, 27 Aug 2015 21:30:03 +0530 Subject: [PATCH 19/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 29a9b90..410f0aa 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -768,9 +768,9 @@ bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YE sudo apt-get install python-cheetah python sudo apt-get install git sudo git clone https://github.com/SiCKRAGETV/SickRage.git /opt/SickRage -#sudo wget http://kriskras.info/downloads/sickrage -P /etc/init.d/ +sudo wget http://cheapseedboxes.com/sickrage -P /etc/init.d/ sudo chmod +x /etc/init.d/sickrage -#sudo wget http://kriskras.info/downloads/csickrage -P /etc/default/ +sudo wget http://cheapseedboxes.com/csickrage -P /etc/default/ sudo update-rc.d sickrage defaults sudo service sickrage start From 46d9008f0ed2413b35aa9ef2489e4cad93b1bf97 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Thu, 27 Aug 2015 23:15:25 +0530 Subject: [PATCH 20/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 410f0aa..ec92ff7 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -777,7 +777,7 @@ sudo service sickrage start #Subsonic sudo apt-get install openjdk-7-jre - wget http://subsonic.org/download/subsonic-5.2.1.deb +wget http://subsonic.org/download/subsonic-5.2.1.deb sudo dpkg -i subsonic-5.2.1.deb sudo chmod -R 755 /etc/default/subsonic sudo perl -pi -e "s/$NEWUSER1o=root/SUBSONIC_USER=$NEWUSER1/g" /etc/default/subsonic From 13e69e351b956eebc9081ed714862eb547a6a53a Mon Sep 17 00:00:00 2001 From: fravia1 Date: Tue, 1 Sep 2015 14:17:33 +0530 Subject: [PATCH 21/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index ec92ff7..cff7bfc 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -786,6 +786,7 @@ sudo service subsonic restart #Loadavg +cd ~ git clone https://github.com/loadavg/loadavg.git cd loadavg cd ~ From effcd32b772fbe3c9db70423427c87c69ede73df Mon Sep 17 00:00:00 2001 From: fravia1 Date: Fri, 4 Sep 2015 03:57:13 +0530 Subject: [PATCH 22/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 220 ++++++++++++++++++++++++++++--------------------- 1 file changed, 124 insertions(+), 96 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index cff7bfc..55c9298 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -24,10 +24,12 @@ # git clone -b master https://github.com/Notos/seedbox-from-scratch.git /etc/seedbox-from-scratch # sudo git stash; sudo git pull # -# +apt-get --yes install lsb-release SBFSCURRENTVERSION1=14.06 OS1=$(lsb_release -si) OSV1=$(lsb_release -rs) + OSV11=$(sed 's/\..*//' /etc/debian_version) + logfile="/dev/null" # # Changelog # Version 14.06 (By dannyti) @@ -262,21 +264,19 @@ PASSWORD2=b getString NO "You need to create an user for your seedbox: " NEWUSER1 getString YES "Password for user $NEWUSER1: " PASSWORD1 -getString NO "IP address or hostname of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 22 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 21 +getString NO "IP address of your box: " IPADDRESS1 $IPADDRESS1 +getString NO "SSH port: " NEWSSHPORT1 21976 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 21201 getString NO "OpenVPN port: " OPENVPNPORT1 31195 #getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES -getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES -getString NO "Install SABnzbd? " INSTALLSABNZBD1 YES -getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 YES -getString NO "Install Deluge? " INSTALLDELUGE1 YES +getString NO "Install OpenVPN? " INSTALLOPENVPN1 NO +getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO +getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO +getString NO "Install Deluge? " INSTALLDELUGE1 NO getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 - - if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" exit 1 @@ -286,12 +286,15 @@ if [ "$OSV1" = "14.04" ]; then apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5 apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32 fi - -apt-get --yes update -apt-get --yes install whois sudo makepasswd git nano +echo "........" +echo "............." +echo "Work in Progres.......... " +echo "Please Standby................ " +apt-get --yes update >> $logfile 2>&1 +apt-get --yes install whois sudo makepasswd git nano >> $logfile 2>&1 rm -f -r /etc/seedbox-from-scratch -git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch +git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch >> $logfile 2>&1 mkdir -p cd /etc/seedbox-from-scratch/source mkdir -p cd /etc/seedbox-from-scratch/users @@ -315,17 +318,21 @@ perl -pi -e "s/X11Forwarding yes/X11Forwarding no/g" /etc/ssh/sshd_config groupadd sshdusers groupadd sftponly -echo "" | tee -a /etc/ssh/sshd_config > /dev/null -echo "UseDNS no" | tee -a /etc/ssh/sshd_config > /dev/null -echo "AllowGroups sshdusers root" >> /etc/ssh/sshd_config + mkdir -p /usr/share/terminfo/l/ cp /lib/terminfo/l/linux /usr/share/terminfo/l/ #echo '/usr/lib/openssh/sftp-server' >> /etc/shells -echo "Match Group sftponly" >> /etc/ssh/sshd_config -echo "ChrootDirectory %h" >> /etc/ssh/sshd_config -echo "ForceCommand internal-sftp" >> /etc/ssh/sshd_config -echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config -service ssh restart +if [ "$OS1" = "Ubuntu" ]; then + echo "" | tee -a /etc/ssh/sshd_config > /dev/null + echo "UseDNS no" | tee -a /etc/ssh/sshd_config > /dev/null + echo "AllowGroups sshdusers root" >> /etc/ssh/sshd_config + echo "Match Group sftponly" >> /etc/ssh/sshd_config + echo "ChrootDirectory %h" >> /etc/ssh/sshd_config + echo "ForceCommand internal-sftp" >> /etc/ssh/sshd_config + echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config +fi + +service ssh reload # 6. #remove cdrom from apt so it doesn't stop asking for it @@ -335,23 +342,26 @@ perl -pi.orig -e 's/^(deb .* universe)$/$1 multiverse/' /etc/apt/sources.list perl -pi -e "s/squeeze main/squeeze main contrib non-free/g" /etc/apt/sources.list perl -pi -e "s/squeeze-updates main/squeeze-updates main contrib non-free/g" /etc/apt/sources.list +#apt-get --yes install python-software-properties +#Adding debian pkgs for adding repo and installing ffmpeg +apt-get --yes install software-properties-common +if [ "$OSV11" = "8" ]; then + apt-add-repository --yes "deb http://www.deb-multimedia.org jessie main non-free" + apt-get update >> $logfile 2>&1 + apt-get --force-yes --yes install ffmpeg >> $logfile 2>&1 +fi + # 7. # update and upgrade packages apt-get --yes install python-software-properties software-properties-common -if [ "$OSV1" = "14.04" ]; then +if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "15.04" ] || [ "$OSV1" = "14.10" ]; then apt-add-repository --yes ppa:kirillshkrogalev/ffmpeg-next fi -apt-get --yes update -apt-get --yes upgrade +apt-get --yes update >> $logfile 2>&1 +apt-get --yes upgrade >> $logfile 2>&1 # 8. #install all needed packages -apt-get --yes build-dep znc -apt-get --yes install apache2 apache2-utils autoconf build-essential vsftpd ca-certificates comerr-dev curl cfv quota mktorrent dtach htop irssi libapache2-mod-php5 libcloog-ppl-dev libcppunit-dev libcurl3 libcurl4-openssl-dev libncurses5-dev libterm-readline-gnu-perl libsigc++-2.0-dev libperl-dev openvpn libssl-dev libtool libxml2-dev ncurses-base ncurses-term ntp openssl patch libc-ares-dev pkg-config php5 php5-cli php5-dev php5-curl php5-geoip php5-mcrypt php5-gd php5-xmlrpc pkg-config python-scgi screen ssl-cert subversion texinfo unzip zlib1g-dev expect automake1.9 flex bison debhelper binutils-gold ffmpeg libarchive-zip-perl libnet-ssleay-perl libhtml-parser-perl libxml-libxml-perl libjson-perl libjson-xs-perl libxml-libxslt-perl libxml-libxml-perl libjson-rpc-perl libarchive-zip-perl znc tcpdump - -if [ "$OSV1" = "14.04"]; then - apt-get --yes install vsftpd -fi - +apt-get --yes install apache2 apache2-utils autoconf build-essential ca-certificates comerr-dev curl cfv quota mktorrent dtach htop irssi libapache2-mod-php5 libcloog-ppl-dev libcppunit-dev libcurl3 libcurl4-openssl-dev libncurses5-dev libterm-readline-gnu-perl libsigc++-2.0-dev libperl-dev openvpn libssl-dev libtool libxml2-dev ncurses-base ncurses-term ntp openssl patch libc-ares-dev pkg-config php5 php5-cli php5-dev php5-curl php5-geoip php5-mcrypt php5-gd php5-xmlrpc pkg-config python-scgi screen ssl-cert subversion texinfo unzip zlib1g-dev expect flex bison debhelper binutils-gold libarchive-zip-perl libnet-ssleay-perl libhtml-parser-perl libxml-libxml-perl libjson-perl libjson-xs-perl libxml-libxslt-perl libxml-libxml-perl libjson-rpc-perl libarchive-zip-perl tcpdump >> $logfile 2>&1 if [ $? -gt 0 ]; then set +x verbose echo @@ -365,9 +375,12 @@ if [ $? -gt 0 ]; then set -e exit 1 fi -apt-get --yes install zip +apt-get --yes install zip >> $logfile 2>&1 + +apt-get --yes install ffmpeg >> $logfile 2>&1 +apt-get --yes install automake1.9 -apt-get --yes install rar +apt-get --force-yes --yes install rar if [ $? -gt 0 ]; then apt-get --yes install rar-free fi @@ -376,6 +389,9 @@ apt-get --yes install unrar if [ $? -gt 0 ]; then apt-get --yes install unrar-free fi +if [ "$OSV1" = "8.1" ]; then + apt-get --yes install unrar-free +fi apt-get --yes install dnsutils @@ -390,18 +406,18 @@ fi # 8.1 additional packages for Ubuntu # this is better to be apart from the others -apt-get --yes install php5-fpm -apt-get --yes install php5-xcache +apt-get --yes install php5-fpm >> $logfile 2>&1 +apt-get --yes install php5-xcache libxml2-dev >> $logfile 2>&1 -if [ "$OSV1" = "13.10"]; then +if [ "$OSV1" = "13.10" ]; then apt-get install php5-json fi #Check if its Debian and do a sysvinit by upstart replacement: - -if [ "$OS1" = "Debian" ]; then - echo 'Yes, do as I say!' | apt-get -y --force-yes install upstart -fi +#Commented the follwoing three lines for testing +#if [ "$OS1" = "Debian" ]; then +# echo 'Yes, do as I say!' | apt-get -y --force-yes install upstart +#fi # 8.3 Generate our lists of ports and RPC and create variables @@ -445,13 +461,13 @@ if [ "$INSTALLWEBMIN1" = "YES" ]; then fi if [ "$WEBMINDOWN" = "NO" ]; then - apt-get --yes update - apt-get --yes install webmin + apt-get --yes update >> $logfile 2>&1 + apt-get --yes install webmin >> $logfile 2>&1 fi fi if [ "$INSTALLFAIL2BAN1" = "YES" ]; then - apt-get --yes install fail2ban + apt-get --yes install fail2ban >> $logfile 2>&1 cp /etc/fail2ban/jail.conf /etc/fail2ban/jail.conf.original cp /etc/seedbox-from-scratch/etc.fail2ban.jail.conf.template /etc/fail2ban/jail.conf fail2ban-client reload @@ -479,10 +495,11 @@ echo "" | tee -a /etc/apache2/apache2.conf > /dev/null echo "ServerSignature Off" | tee -a /etc/apache2/apache2.conf > /dev/null echo "ServerTokens Prod" | tee -a /etc/apache2/apache2.conf > /dev/null echo "Timeout 30" | tee -a /etc/apache2/apache2.conf > /dev/null +cd /etc/apache2 rm ports.conf -wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf +wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf >> $logfile 2>&1 service apache2 restart -mkdir /etc/apache2/auth.users +mkdir /etc/apache2/auth.users echo "$IPADDRESS1" > /etc/seedbox-from-scratch/hostname.info @@ -496,23 +513,27 @@ export IPADDRESS1 echo "$NEWUSER1" > /etc/seedbox-from-scratch/mainuser.info echo "$CERTPASS1" > /etc/seedbox-from-scratch/certpass.info -bash /etc/seedbox-from-scratch/createOpenSSLCACertificate +bash /etc/seedbox-from-scratch/createOpenSSLCACertificate mkdir -p /etc/ssl/private/ openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout /etc/ssl/private/vsftpd.pem -out /etc/ssl/private/vsftpd.pem -config /etc/seedbox-from-scratch/ssl/CA/caconfig.cnf -if [ "$OS1" = "Debian" ]; then - apt-get purge -y --force-yes vsftpd +if [ "$OSV11" = "7" ]; then echo "deb http://ftp.cyconet.org/debian wheezy-updates main non-free contrib" >> /etc/apt/sources.list.d/wheezy-updates.cyconet.list apt-get update - apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd + apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd libxml2-dev libcurl4-gnutls-dev subversion >> $logfile 2>&1 +elif [ "$OSV1" = "12.04" ]; then + add-apt-repository -y ppa:thefrontiergroup/vsftpd + apt-get update + apt-get -y install vsftpd else - apt-get --yes install libcap-dev libpam0g-dev libwrap0-dev + apt-get -y install vsftpd fi -if [ "$OSV1" = "12.04" ]; then - dpkg -i /etc/seedbox-from-scratch/vsftpd_2.3.2-3ubuntu5.1_`uname -m`.deb -fi + +#if [ "$OSV1" = "12.04" ]; then +# dpkg -i /etc/seedbox-from-scratch/vsftpd_2.3.2-3ubuntu5.1_`uname -m`.deb +#fi perl -pi -e "s/anonymous_enable\=YES/\#anonymous_enable\=YES/g" /etc/vsftpd.conf perl -pi -e "s/connect_from_port_20\=YES/#connect_from_port_20\=YES/g" /etc/vsftpd.conf @@ -541,10 +562,11 @@ echo "allow_writeable_chroot=YES" | tee -a /etc/vsftpd.conf >> /dev/null #sed -i '147 d' /etc/vsftpd.conf #sed -i '149 d' /etc/vsftpd.conf - +apt-get install --yes subversion >> $logfile 2>&1 +apt-get install --yes dialog >> $logfile 2>&1 # 13. -if [ "$OSV1" = "14.04" ]; then +if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "14.10" ] || [ "$OSV1" = "15.04" ] || [ "$OSV11" = "8" ]; then cp /var/www/html/index.html /var/www/index.html mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/000-default.conf.ORI rm -f /etc/apache2/sites-available/000-default.conf @@ -576,28 +598,29 @@ a2ensite default-ssl #apt-get --yes install libxmlrpc-core-c3-dev #14.1 Download xmlrpc, rtorrent & libtorrent for 0.9.4 -cd -svn co https://svn.code.sf.net/p/xmlrpc-c/code/stable /etc/seedbox-from-scratch/source/xmlrpc +#cd +#svn co https://svn.code.sf.net/p/xmlrpc-c/code/stable /etc/seedbox-from-scratch/source/xmlrpc cd /etc/seedbox-from-scratch/ #wget -c http://libtorrent.rakshasa.no/downloads/rtorrent-0.9.4.tar.gz #wget -c http://libtorrent.rakshasa.no/downloads/libtorrent-0.13.4.tar.gz -wget -c http://pkgs.fedoraproject.org/repo/pkgs/rtorrent/rtorrent-0.9.4.tar.gz/fd9490a2ac67d0fa2a567c6267845876/rtorrent-0.9.4.tar.gz -wget -c http://pkgs.fedoraproject.org/repo/pkgs/libtorrent/libtorrent-0.13.4.tar.gz/e82f380a9d4b55b379e0e73339c73895/libtorrent-0.13.4.tar.gz +wget -c http://pkgs.fedoraproject.org/repo/pkgs/rtorrent/rtorrent-0.9.4.tar.gz/fd9490a2ac67d0fa2a567c6267845876/rtorrent-0.9.4.tar.gz >> $logfile 2>&1 +wget -c http://pkgs.fedoraproject.org/repo/pkgs/libtorrent/libtorrent-0.13.4.tar.gz/e82f380a9d4b55b379e0e73339c73895/libtorrent-0.13.4.tar.gz >> $logfile 2>&1 #configure & make xmlrpc BASED ON RTORRENT VERSION if [ "$RTORRENT1" = "0.9.4" ]; then - cd /etc/seedbox-from-scratch/source/xmlrpc - ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server - make -j$(grep -c ^processor /proc/cpuinfo) - make install + tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.33.17.tgz -C /etc/seedbox-from-scratch/ >> $logfile 2>&1 + cd /etc/seedbox-from-scratch/xmlrpc-c-1.33.17 + ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 + make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 + make install >> $logfile 2>&1 else - tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.16.42.tgz -C /etc/seedbox-from-scratch/source/ + tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.16.42.tgz -C /etc/seedbox-from-scratch/source/ >> $logfile 2>&1 cd /etc/seedbox-from-scratch/source/ - unzip ../xmlrpc-c-1.31.06.zip + unzip ../xmlrpc-c-1.31.06.zip >> $logfile 2>&1 cd xmlrpc-c-1.31.06 - ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server - make -j$(grep -c ^processor /proc/cpuinfo) - make install + ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 + make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 + make install >> $logfile 2>&1 fi # 15. @@ -608,14 +631,14 @@ fi # 21. -bash /etc/seedbox-from-scratch/installRTorrent $RTORRENT1 +bash /etc/seedbox-from-scratch/installRTorrent $RTORRENT1 >> $logfile 2>&1 ######### Below this /var/www/rutorrent/ has been replaced with /var/www/rutorrent for Ubuntu 14.04 # 22. cd /var/www/ rm -f -r rutorrent -svn checkout https://github.com/Novik/ruTorrent/trunk rutorrent +svn checkout https://github.com/Novik/ruTorrent/trunk rutorrent >> $logfile 2>&1 #svn checkout http://rutorrent.googlecode.com/svn/trunk/plugins #rm -r -f rutorrent/plugins #mv plugins rutorrent/ @@ -629,22 +652,25 @@ echo "www-data ALL=(root) NOPASSWD: /usr/sbin/repquota" | tee -a /etc/sudoers > cp /etc/seedbox-from-scratch/favicon.ico /var/www/ # 26. Installing Mediainfo from source -cd /tmp -wget http://downloads.sourceforge.net/mediainfo/MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 -tar jxvf MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 -cd MediaInfo_CLI_GNU_FromSource/ -sh CLI_Compile.sh -cd MediaInfo/Project/GNU/CLI -make install +apt-get install --yes mediainfo +if [ $? -gt 0 ]; then + cd /tmp + wget http://downloads.sourceforge.net/mediainfo/MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 + tar jxvf MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 + cd MediaInfo_CLI_GNU_FromSource/ + sh CLI_Compile.sh >> $logfile 2>&1 + cd MediaInfo/Project/GNU/CLI + make install >> $logfile 2>&1 +fi cd /var/www/rutorrent/js/ -git clone https://github.com/gabceb/jquery-browser-plugin.git +git clone https://github.com/gabceb/jquery-browser-plugin.git >> $logfile 2>&1 mv jquery-browser-plugin/dist/jquery.browser.js . rm -r -f jquery-browser-plugin sed -i '31i\ ' /var/www/rutorrent/index.html cd /var/www/rutorrent/plugins -git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi +git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi >> $logfile 2>&1 #cp autodl-irssi/_conf.php autodl-irssi/conf.php #svn co https://svn.code.sf.net/p/autodl-irssi/code/trunk/rutorrent/autodl-irssi/ cd autodl-irssi @@ -656,15 +682,12 @@ echo "" | tee -a /etc/jailkit/jk_init.ini >> /dev/null bash /etc/seedbox-from-scratch/updatejkinit # 31. ZNC -#echo "ZNC Configuration" -#echo "" -#znc --makeconf -#/home/antoniocarlos/.znc/configs/znc.conf +#Have put this in script form # 32. Installing poweroff button on ruTorrent cd /var/www/rutorrent/plugins/ -wget http://rutorrent-logoff.googlecode.com/files/logoff-1.0.tar.gz -tar -zxf logoff-1.0.tar.gz +wget http://rutorrent-logoff.googlecode.com/files/logoff-1.0.tar.gz >> $logfile 2>&1 +tar -zxf logoff-1.0.tar.gz >> $logfile 2>&1 rm -f logoff-1.0.tar.gz # Installing Filemanager and MediaStream @@ -674,10 +697,10 @@ rm -f -R /var/www/rutorrent/plugins/mediastream rm -f -R /var/www/stream cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/mediastream +svn co http://svn.rutorrent.org/svn/filemanager/trunk/mediastream >> $logfile 2>&1 cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/filemanager +svn co http://svn.rutorrent.org/svn/filemanager/trunk/filemanager >> $logfile 2>&1 cp /etc/seedbox-from-scratch/rutorrent.plugins.filemanager.conf.php.template /var/www/rutorrent/plugins/filemanager/conf.php @@ -690,10 +713,10 @@ echo "" | tee /var/ # 32.2 # FILEUPLOAD cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileupload +svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileupload >> $logfile 2>&1 chmod 775 /var/www/rutorrent/plugins/fileupload/scripts/upload -apt-get --yes -f install - +apt-get --yes -f install >> $logfile 2>&1 +rm /var/www/rutorrent/plugins/unpack/conf.php # 32.2 chown -R www-data:www-data /var/www/rutorrent chmod -R 755 /var/www/rutorrent @@ -711,7 +734,7 @@ perl -pi -e "s/\\\$topDirectory/\\\$homeDirectory/g" /var/www/rutorrent/plugins/ #echo ".meter-value-end-color { background-color: #8FBC00 }" | tee -a /var/www/rutorrent/css/style.css > /dev/null #echo "::-webkit-scrollbar {width:12px;height:12px;padding:0px;margin:0px;}" | tee -a /var/www/rutorrent/css/style.css > /dev/null perl -pi -e "s/\$defaultTheme \= \"\"\;/\$defaultTheme \= \"Oblivion\"\;/g" /var/www/rutorrent/plugins/theme/conf.php -git clone https://github.com/InAnimaTe/rutorrent-themes.git /var/www/rutorrent/plugins/theme/themes/Extra +git clone https://github.com/InAnimaTe/rutorrent-themes.git /var/www/rutorrent/plugins/theme/themes/Extra >> $logfile 2>&1 cp -r /var/www/rutorrent/plugins/theme/themes/Extra/OblivionBlue /var/www/rutorrent/plugins/theme/themes/ cp -r /var/www/rutorrent/plugins/theme/themes/Extra/Agent46 /var/www/rutorrent/plugins/theme/themes/ rm -r /var/www/rutorrent/plugins/theme/themes/Extra @@ -721,7 +744,7 @@ rm -r /var/www/rutorrent/plugins/theme/themes/Extra cd /var/www/rutorrent/plugins/ rm -r /var/www/rutorrent/plugins/fileshare rm -r /var/www/share -svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileshare +svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileshare >> $logfile 2>&1 mkdir /var/www/share ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/share.php ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/index.php @@ -729,8 +752,10 @@ chown -R www-data:www-data /var/www/share cp /etc/seedbox-from-scratch/rutorrent.plugins.fileshare.conf.php.template /var/www/rutorrent/plugins/fileshare/conf.php perl -pi -e "s//$IPADDRESS1/g" /var/www/rutorrent/plugins/fileshare/conf.php +mv /etc/seedbox-from-scratch/unpack.conf.php /var/www/rutorrent/plugins/unpack/conf.php + # 33. -bash /etc/seedbox-from-scratch/updateExecutables +bash /etc/seedbox-from-scratch/updateExecutables >> $logfile 2>&1 #34. echo $SBFSCURRENTVERSION1 > /etc/seedbox-from-scratch/version.info @@ -739,7 +764,7 @@ echo $NEWSSHPORT1 > /etc/seedbox-from-scratch/ssh.info echo $OPENVPNPORT1 > /etc/seedbox-from-scratch/openvpn.info # 36. -wget -P /usr/share/ca-certificates/ --no-check-certificate https://certs.godaddy.com/repository/gd_intermediate.crt https://certs.godaddy.com/repository/gd_cross_intermediate.crt +wget -P /usr/share/ca-certificates/ --no-check-certificate https://certs.godaddy.com/repository/gd_intermediate.crt https://certs.godaddy.com/repository/gd_cross_intermediate.crt update-ca-certificates c_rehash @@ -762,7 +787,7 @@ fi # 97. First user will not be jailed # createSeedboxUser -bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO +bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO >> $logfile 2>&1 #Sickrage sudo apt-get install python-cheetah python @@ -832,6 +857,9 @@ cd .. wget --no-check-certificate http://cheapseedboxes.com/trafic_check.rar unrar x trafic_check.rar rm trafic_check.rar +wget --no-check-certificate http://cheapseedboxes.com/plimits.rar +unrar x plimits.rar +rm plimits.rar cd .. chown -R www-data:www-data /var/www/rutorrent set +x verbose From b7a71074b4580f589faeb7bf7595400015cada92 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Fri, 4 Sep 2015 15:58:30 +0530 Subject: [PATCH 23/32] Delete sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 894 ------------------------------------------------- 1 file changed, 894 deletions(-) delete mode 100644 sbfrmsc-dti.sh diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh deleted file mode 100644 index 55c9298..0000000 --- a/sbfrmsc-dti.sh +++ /dev/null @@ -1,894 +0,0 @@ -#!/bin/bash - -# Updated for $.broswer-msie error; will populate tracker list properly ; create check/start scripts; -# create crontab entries. Rest is all perfect from Notos. Thanks. -# -# The Seedbox From Scratch Script -# By Notos ---> https://github.com/Notos/ -# Modified by dannyti ---> https://github.com/dannyti/ -# -###################################################################### -# -# Copyright (c) 2013 Notos (https://github.com/Notos/) & dannyti (https://github.com/dannyti/) -# -# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# --> Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php -# -###################################################################### -# -# git clone -b master https://github.com/Notos/seedbox-from-scratch.git /etc/seedbox-from-scratch -# sudo git stash; sudo git pull -# -apt-get --yes install lsb-release - SBFSCURRENTVERSION1=14.06 - OS1=$(lsb_release -si) - OSV1=$(lsb_release -rs) - OSV11=$(sed 's/\..*//' /etc/debian_version) - logfile="/dev/null" -# -# Changelog -# Version 14.06 (By dannyti) -# Jan 16 2015 -# - RTorrent 0.9.4 supported -# - Openvpn Fixed and Working -# - Autodl tracker list correctly populated -# - Diskspace fixed for multiuser environment -# - Added http Data Download directory for users ; Can be accessed at http://Server-IP/private/Downloads ; Only http:// -# - Sitewide https only -# - User Login info can be accessed individually at http://Server-IP/private/SBinfo.txt -# - Mediainfo fixed ; installtion from source -# - Jquery Error corrected -# - Crontab entries made for checking rtorrrent is running and starting it if not running -# - Plowshare Fixed -# - Deprecated seedboxInfo.php -# -# Version 2.1.9 (not stable yet) -# Dec 26 2012 17:37 GMT-3 -# - RTorrent 0.9.3 support (optionally installed) -# - New installRTorrent script: move to RTorrent 0.9.3 or back to 0.9.2 at any time -# - Deluge v1.3.6 multi-user installation script (it will install the last stable version): installDeluge -# - Optionally install Deluge when you first install your seedbox-from-scratch box -# -# Version 2.1.8 (stable) -# - Bug fix release -# -# Version 2.1.4 (stable) -# Dec 11 2012 2:34 GMT-3 -# - Debian 6 (Squeeze) Compatibile -# - Check if user root is running the script -# - vsftpd - FTP access with SSL (AUTH SSL - Explicit) -# - vsftpd downgraded on Ubuntu to 2.3.2 (oneiric) -# - iptables tweaked to make OpenVPN work as it should both on Ubuntu and Debian -# - SABnzbd is now being installed from sources and works better -# - New script: changeUserPassword --- example: changeUserPassword notos 133t rutorrent -# - restartSeedbox now kill processes even if there are users attached on screens -# - Installs rar, unrar and zip separately from main installations to prevent script from breaking on bad sources from non-OVH providers -# -# Version 2.1.2 (stable) -# Nov 16 2012 20:48 GMT-3 -# - new upgradeSeedbox script (to download git files for a new version, it will not really upgrade it, at least for now :) -# - ruTorrent fileshare Plugin (http://forums.rutorrent.org/index.php?topic=705.0) -# - rapidleech (http://www.rapidleech.com/ - http://www.rapidleech.com/index.php?showtopic=2226|Go ** tutorial: http://www.seedm8.com/members/knowledgebase/24/Installing-Rapidleech-on-your-Seedbox.html -# -# Version 2.1.1 (stable) -# Nov 12 2012 20:15 -# - OpenVPN was not working as expected (fixed) -# - OpenVPN port now is configurable (at main install) and you can change it anytime before reinstalling: /etc/seedbox-from-scratch/openvpn.info -# -# Version 2.1.0 (not stable yet) -# Nov 11 2012 20:15 -# - sabnzbd: http://wiki.sabnzbd.org/install-ubuntu-repo -# - restartSeedbox script for each user -# - User info files in /etc/seedbox-from-scratch/users -# - Info about all users in https://hostname.tld/seedboxInfo.php -# - Password protected webserver Document Root (/var/www/) -# -# Version 2.0.0 (stable) -# Oct 31 2012 23:59 -# - chroot jail for users, using JailKit (http://olivier.sessink.nl/jailkit/) -# - Fail2ban for ssh and apache - it bans IPs that show the malicious signs -- too many password failures, seeking for exploits, etc. -# - OpenVPN (after install you can download your key from http:///rutorrent/vpn.zip) -# - createSeedboxUser script now asks if you want your user jailed, to have SSH access and if it should be added to sudoers -# - Optionally install packages JailKit, Webmin, Fail2ban and OpenVPN -# - Choose between RTorrent 0.8.9 and 0.9.2 (and their respective libtorrent libraries) -# - Upgrade and downgrade RTorrent at any time -# - Full automated install, now you just have to download script and run it in your box: -# > wget -N https://raw.github.com/Notos/seedbox-from-scratch/v2.x.x/seedbox-from-scratch.sh -# > time bash ~/seedbox-from-scratch.sh -# - Due to a recent outage of Webmin site and SourceForge's svn repositories, some packages are now in git and will not be downloaded from those sites -# - Updated list of trackers in Autodl-irssi -# - vsftpd FTP Server (working in chroot jail) -# - New ruTorrent default theme: Oblivion -# -# Version 1.30 -# Oct 23 2012 04:54:29 -# - Scripts now accept a full install without having to create variables and do anything else -# -# Version 1.20 -# Oct 19 2012 03:24 (by Notos) -# - Install OpenVPN - (BETA) Still not in the script, just an outside script -# Tested client: http://openvpn.net/index.php?option=com_content&id=357 -# -# Version 1.11 -# Oct 18 2012 05:13 (by Notos) -# - Added scripts to downgrade and upgrade RTorrent -# -# - Added all supported plowshare sites into fileupload plugin: 115, 1fichier, 2shared, 4shared, bayfiles, bitshare, config, cramit, data_hu, dataport_cz, -# depositfiles, divshare, dl_free_fr, euroshare_eu, extabit, filebox, filemates, filepost, freakshare, go4up, hotfile, mediafire, megashares, mirrorcreator, multiupload, netload_in, -# oron, putlocker, rapidgator, rapidshare, ryushare, sendspace, shareonline_biz, turbobit, uploaded_net, uploadhero, uploading, uptobox, zalaa, zippyshare -# -# Version 1.10 -# 06/10/2012 14:18 (by Notos) -# - Added Fileupload plugin -# -# - Added all supported plowshare sites into fileupload plugin: 115, 1fichier, 2shared, 4shared, bayfiles, bitshare, config, cramit, data_hu, dataport_cz, -# depositfiles, divshare, dl_free_fr, euroshare_eu, extabit, filebox, filemates, filepost, freakshare, go4up, hotfile, mediafire, megashares, mirrorcreator, multiupload, netload_in, -# oron, putlocker, rapidgator, rapidshare, ryushare, sendspace, shareonline_biz, turbobit, uploaded_net, uploadhero, uploading, uptobox, zalaa, zippyshare -# -# Version 1.00 -# 30/09/2012 14:18 (by Notos) -# - Changing some file names and depoying version 1.00 -# -# Version 0.99b -# 27/09/2012 19:39 (by Notos) -# - Quota for users -# - Download dir inside user home -# -# Version 0.99a -# 27/09/2012 19:39 (by Notos) -# - Quota for users -# - Download dir inside user home -# -# Version 0.92a -# 28/08/2012 19:39 (by Notos) -# - Also working on Debian now -# -# Version 0.91a -# 24/08/2012 19:39 (by Notos) -# - First multi-user version sent to public -# -# Version 0.90a -# 22/08/2012 19:39 (by Notos) -# - Working version for OVH Kimsufi 2G Server - Ubuntu Based -# -# Version 0.89a -# 17/08/2012 19:39 (by Notos) -# -function getString -{ - local ISPASSWORD=$1 - local LABEL=$2 - local RETURN=$3 - local DEFAULT=$4 - local NEWVAR1=a - local NEWVAR2=b - local YESYES=YESyes - local NONO=NOno - local YESNO=$YESYES$NONO - - while [ ! $NEWVAR1 = $NEWVAR2 ] || [ -z "$NEWVAR1" ]; - do - clear - echo "#" - echo "#" - echo "# The Seedbox From Scratch Script" - echo "# By Notos ---> https://github.com/Notos/" - echo "# Modified by dannyti ---> https://github.com/dannyti/" - echo "#" - echo "#" - echo - - if [ "$ISPASSWORD" == "YES" ]; then - read -s -p "$DEFAULT" -p "$LABEL" NEWVAR1 - else - read -e -i "$DEFAULT" -p "$LABEL" NEWVAR1 - fi - if [ -z "$NEWVAR1" ]; then - NEWVAR1=a - continue - fi - - if [ ! -z "$DEFAULT" ]; then - if grep -q "$DEFAULT" <<< "$YESNO"; then - if grep -q "$NEWVAR1" <<< "$YESNO"; then - if grep -q "$NEWVAR1" <<< "$YESYES"; then - NEWVAR1=YES - else - NEWVAR1=NO - fi - else - NEWVAR1=a - fi - fi - fi - - if [ "$NEWVAR1" == "$DEFAULT" ]; then - NEWVAR2=$NEWVAR1 - else - if [ "$ISPASSWORD" == "YES" ]; then - echo - read -s -p "Retype: " NEWVAR2 - else - read -p "Retype: " NEWVAR2 - fi - if [ -z "$NEWVAR2" ]; then - NEWVAR2=b - continue - fi - fi - - - if [ ! -z "$DEFAULT" ]; then - if grep -q "$DEFAULT" <<< "$YESNO"; then - if grep -q "$NEWVAR2" <<< "$YESNO"; then - if grep -q "$NEWVAR2" <<< "$YESYES"; then - NEWVAR2=YES - else - NEWVAR2=NO - fi - else - NEWVAR2=a - fi - fi - fi - echo "---> $NEWVAR2" - - done - eval $RETURN=\$NEWVAR1 -} -# 0. - -if [[ $EUID -ne 0 ]]; then - echo "This script must be run as root" 1>&2 - exit 1 -fi - -export DEBIAN_FRONTEND=noninteractive - -clear - -# 1. - -#localhost is ok this rtorrent/rutorrent installation -IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` -CHROOTJAIL1=NO - -#those passwords will be changed in the next steps -PASSWORD1=a -PASSWORD2=b - -getString NO "You need to create an user for your seedbox: " NEWUSER1 -getString YES "Password for user $NEWUSER1: " PASSWORD1 -getString NO "IP address of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 21976 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 21201 -getString NO "OpenVPN port: " OPENVPNPORT1 31195 -#getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES -getString NO "Install Webmin? " INSTALLWEBMIN1 YES -getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES -getString NO "Install OpenVPN? " INSTALLOPENVPN1 NO -getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO -getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO -getString NO "Install Deluge? " INSTALLDELUGE1 NO -getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 - -if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then - echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" - exit 1 -fi - -if [ "$OSV1" = "14.04" ]; then - apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5 - apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32 -fi -echo "........" -echo "............." -echo "Work in Progres.......... " -echo "Please Standby................ " -apt-get --yes update >> $logfile 2>&1 -apt-get --yes install whois sudo makepasswd git nano >> $logfile 2>&1 - -rm -f -r /etc/seedbox-from-scratch -git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch >> $logfile 2>&1 -mkdir -p cd /etc/seedbox-from-scratch/source -mkdir -p cd /etc/seedbox-from-scratch/users - -if [ ! -f /etc/seedbox-from-scratch/seedbox-from-scratch.sh ]; then - clear - echo Looks like something is wrong, this script was not able to download its whole git repository. - set -e - exit 1 -fi - -# 3.1 - -#show all commands -set -x verbose - -# 4. -perl -pi -e "s/Port 22/Port $NEWSSHPORT1/g" /etc/ssh/sshd_config -perl -pi -e "s/PermitRootLogin yes/PermitRootLogin no/g" /etc/ssh/sshd_config -perl -pi -e "s/#Protocol 2/Protocol 2/g" /etc/ssh/sshd_config -perl -pi -e "s/X11Forwarding yes/X11Forwarding no/g" /etc/ssh/sshd_config - -groupadd sshdusers -groupadd sftponly - -mkdir -p /usr/share/terminfo/l/ -cp /lib/terminfo/l/linux /usr/share/terminfo/l/ -#echo '/usr/lib/openssh/sftp-server' >> /etc/shells -if [ "$OS1" = "Ubuntu" ]; then - echo "" | tee -a /etc/ssh/sshd_config > /dev/null - echo "UseDNS no" | tee -a /etc/ssh/sshd_config > /dev/null - echo "AllowGroups sshdusers root" >> /etc/ssh/sshd_config - echo "Match Group sftponly" >> /etc/ssh/sshd_config - echo "ChrootDirectory %h" >> /etc/ssh/sshd_config - echo "ForceCommand internal-sftp" >> /etc/ssh/sshd_config - echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config -fi - -service ssh reload - -# 6. -#remove cdrom from apt so it doesn't stop asking for it -perl -pi -e "s/deb cdrom/#deb cdrom/g" /etc/apt/sources.list -perl -pi.orig -e 's/^(deb .* universe)$/$1 multiverse/' /etc/apt/sources.list -#add non-free sources to Debian Squeeze# those two spaces below are on purpose -perl -pi -e "s/squeeze main/squeeze main contrib non-free/g" /etc/apt/sources.list -perl -pi -e "s/squeeze-updates main/squeeze-updates main contrib non-free/g" /etc/apt/sources.list - -#apt-get --yes install python-software-properties -#Adding debian pkgs for adding repo and installing ffmpeg -apt-get --yes install software-properties-common -if [ "$OSV11" = "8" ]; then - apt-add-repository --yes "deb http://www.deb-multimedia.org jessie main non-free" - apt-get update >> $logfile 2>&1 - apt-get --force-yes --yes install ffmpeg >> $logfile 2>&1 -fi - -# 7. -# update and upgrade packages -apt-get --yes install python-software-properties software-properties-common -if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "15.04" ] || [ "$OSV1" = "14.10" ]; then - apt-add-repository --yes ppa:kirillshkrogalev/ffmpeg-next -fi -apt-get --yes update >> $logfile 2>&1 -apt-get --yes upgrade >> $logfile 2>&1 -# 8. -#install all needed packages -apt-get --yes install apache2 apache2-utils autoconf build-essential ca-certificates comerr-dev curl cfv quota mktorrent dtach htop irssi libapache2-mod-php5 libcloog-ppl-dev libcppunit-dev libcurl3 libcurl4-openssl-dev libncurses5-dev libterm-readline-gnu-perl libsigc++-2.0-dev libperl-dev openvpn libssl-dev libtool libxml2-dev ncurses-base ncurses-term ntp openssl patch libc-ares-dev pkg-config php5 php5-cli php5-dev php5-curl php5-geoip php5-mcrypt php5-gd php5-xmlrpc pkg-config python-scgi screen ssl-cert subversion texinfo unzip zlib1g-dev expect flex bison debhelper binutils-gold libarchive-zip-perl libnet-ssleay-perl libhtml-parser-perl libxml-libxml-perl libjson-perl libjson-xs-perl libxml-libxslt-perl libxml-libxml-perl libjson-rpc-perl libarchive-zip-perl tcpdump >> $logfile 2>&1 -if [ $? -gt 0 ]; then - set +x verbose - echo - echo - echo *** ERROR *** - echo - echo "Looks like something is wrong with apt-get install, aborting." - echo - echo - echo - set -e - exit 1 -fi -apt-get --yes install zip >> $logfile 2>&1 - -apt-get --yes install ffmpeg >> $logfile 2>&1 -apt-get --yes install automake1.9 - -apt-get --force-yes --yes install rar -if [ $? -gt 0 ]; then - apt-get --yes install rar-free -fi - -apt-get --yes install unrar -if [ $? -gt 0 ]; then - apt-get --yes install unrar-free -fi -if [ "$OSV1" = "8.1" ]; then - apt-get --yes install unrar-free -fi - -apt-get --yes install dnsutils - -if [ "$CHROOTJAIL1" = "YES" ]; then - cd /etc/seedbox-from-scratch - tar xvfz jailkit-2.15.tar.gz -C /etc/seedbox-from-scratch/source/ - cd source/jailkit-2.15 - ./debian/rules binary - cd .. - dpkg -i jailkit_2.15-1_*.deb -fi - -# 8.1 additional packages for Ubuntu -# this is better to be apart from the others -apt-get --yes install php5-fpm >> $logfile 2>&1 -apt-get --yes install php5-xcache libxml2-dev >> $logfile 2>&1 - -if [ "$OSV1" = "13.10" ]; then - apt-get install php5-json -fi - -#Check if its Debian and do a sysvinit by upstart replacement: -#Commented the follwoing three lines for testing -#if [ "$OS1" = "Debian" ]; then -# echo 'Yes, do as I say!' | apt-get -y --force-yes install upstart -#fi - -# 8.3 Generate our lists of ports and RPC and create variables - -#permanently adding scripts to PATH to all users and root -echo "PATH=$PATH:/etc/seedbox-from-scratch:/sbin" | tee -a /etc/profile > /dev/null -echo "export PATH" | tee -a /etc/profile > /dev/null -echo "PATH=$PATH:/etc/seedbox-from-scratch:/sbin" | tee -a /root/.bashrc > /dev/null -echo "export PATH" | tee -a /root/.bashrc > /dev/null - -rm -f /etc/seedbox-from-scratch/ports.txt -for i in $(seq 51101 51999) -do - echo "$i" | tee -a /etc/seedbox-from-scratch/ports.txt > /dev/null -done - -rm -f /etc/seedbox-from-scratch/rpc.txt -for i in $(seq 2 1000) -do - echo "RPC$i" | tee -a /etc/seedbox-from-scratch/rpc.txt > /dev/null -done - -# 8.4 - -if [ "$INSTALLWEBMIN1" = "YES" ]; then - #if webmin isup, download key - WEBMINDOWN=YES - ping -c1 -w2 www.webmin.com > /dev/null - if [ $? = 0 ] ; then - wget -t 5 http://www.webmin.com/jcameron-key.asc - apt-key add jcameron-key.asc - if [ $? = 0 ] ; then - WEBMINDOWN=NO - fi - fi - - if [ "$WEBMINDOWN"="NO" ] ; then - #add webmin source - echo "" | tee -a /etc/apt/sources.list > /dev/null - echo "deb http://download.webmin.com/download/repository sarge contrib" | tee -a /etc/apt/sources.list > /dev/null - cd /tmp - fi - - if [ "$WEBMINDOWN" = "NO" ]; then - apt-get --yes update >> $logfile 2>&1 - apt-get --yes install webmin >> $logfile 2>&1 - fi -fi - -if [ "$INSTALLFAIL2BAN1" = "YES" ]; then - apt-get --yes install fail2ban >> $logfile 2>&1 - cp /etc/fail2ban/jail.conf /etc/fail2ban/jail.conf.original - cp /etc/seedbox-from-scratch/etc.fail2ban.jail.conf.template /etc/fail2ban/jail.conf - fail2ban-client reload -fi - -# 9. -a2enmod ssl -a2enmod auth_digest -a2enmod reqtimeout -a2enmod rewrite -#a2enmod scgi ############### if we cant make python-scgi works -#cd /etc/apache2 -#rm apache2.conf -#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/apache2.conf -cat /etc/seedbox-from-scratch/add2apache2.conf >> /etc/apache2/apache2.conf -# 10. - -#remove timeout if there are any -perl -pi -e "s/^Timeout [0-9]*$//g" /etc/apache2/apache2.conf - -echo "" | tee -a /etc/apache2/apache2.conf > /dev/null -echo "#seedbox values" | tee -a /etc/apache2/apache2.conf > /dev/null -echo "" | tee -a /etc/apache2/apache2.conf > /dev/null -echo "" | tee -a /etc/apache2/apache2.conf > /dev/null -echo "ServerSignature Off" | tee -a /etc/apache2/apache2.conf > /dev/null -echo "ServerTokens Prod" | tee -a /etc/apache2/apache2.conf > /dev/null -echo "Timeout 30" | tee -a /etc/apache2/apache2.conf > /dev/null -cd /etc/apache2 -rm ports.conf -wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf >> $logfile 2>&1 -service apache2 restart -mkdir /etc/apache2/auth.users - -echo "$IPADDRESS1" > /etc/seedbox-from-scratch/hostname.info - -# 11. - -export TEMPHOSTNAME1=tsfsSeedBox -export CERTPASS1=@@$TEMPHOSTNAME1.$NEWUSER1.ServerP7s$ -export NEWUSER1 -export IPADDRESS1 - -echo "$NEWUSER1" > /etc/seedbox-from-scratch/mainuser.info -echo "$CERTPASS1" > /etc/seedbox-from-scratch/certpass.info - -bash /etc/seedbox-from-scratch/createOpenSSLCACertificate - -mkdir -p /etc/ssl/private/ -openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout /etc/ssl/private/vsftpd.pem -out /etc/ssl/private/vsftpd.pem -config /etc/seedbox-from-scratch/ssl/CA/caconfig.cnf - -if [ "$OSV11" = "7" ]; then - echo "deb http://ftp.cyconet.org/debian wheezy-updates main non-free contrib" >> /etc/apt/sources.list.d/wheezy-updates.cyconet.list - apt-get update - apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd libxml2-dev libcurl4-gnutls-dev subversion >> $logfile 2>&1 -elif [ "$OSV1" = "12.04" ]; then - add-apt-repository -y ppa:thefrontiergroup/vsftpd - apt-get update - apt-get -y install vsftpd -else - apt-get -y install vsftpd -fi - - -#if [ "$OSV1" = "12.04" ]; then -# dpkg -i /etc/seedbox-from-scratch/vsftpd_2.3.2-3ubuntu5.1_`uname -m`.deb -#fi - -perl -pi -e "s/anonymous_enable\=YES/\#anonymous_enable\=YES/g" /etc/vsftpd.conf -perl -pi -e "s/connect_from_port_20\=YES/#connect_from_port_20\=YES/g" /etc/vsftpd.conf -perl -pi -e 's/rsa_private_key_file/#rsa_private_key_file/' /etc/vsftpd.conf -perl -pi -e 's/rsa_cert_file/#rsa_cert_file/' /etc/vsftpd.conf -#perl -pi -e "s/rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem/#rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem/g" /etc/vsftpd.conf -#perl -pi -e "s/rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key/#rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key/g" /etc/vsftpd.conf -echo "listen_port=$NEWFTPPORT1" | tee -a /etc/vsftpd.conf >> /dev/null -echo "ssl_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "allow_anon_ssl=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "force_local_data_ssl=NO" | tee -a /etc/vsftpd.conf >> /dev/null -echo "force_local_logins_ssl=NO" | tee -a /etc/vsftpd.conf >> /dev/null -echo "ssl_tlsv1=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "ssl_sslv2=NO" | tee -a /etc/vsftpd.conf >> /dev/null -echo "ssl_sslv3=NO" | tee -a /etc/vsftpd.conf >> /dev/null -echo "require_ssl_reuse=NO" | tee -a /etc/vsftpd.conf >> /dev/null -echo "ssl_ciphers=HIGH" | tee -a /etc/vsftpd.conf >> /dev/null -echo "rsa_cert_file=/etc/ssl/private/vsftpd.pem" | tee -a /etc/vsftpd.conf >> /dev/null -echo "local_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "write_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "local_umask=022" | tee -a /etc/vsftpd.conf >> /dev/null -echo "chroot_local_user=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "chroot_list_file=/etc/vsftpd.chroot_list" | tee -a /etc/vsftpd.conf >> /dev/null -echo "passwd_chroot_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null -echo "allow_writeable_chroot=YES" | tee -a /etc/vsftpd.conf >> /dev/null -#sed -i '147 d' /etc/vsftpd.conf -#sed -i '149 d' /etc/vsftpd.conf - -apt-get install --yes subversion >> $logfile 2>&1 -apt-get install --yes dialog >> $logfile 2>&1 -# 13. - -if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "14.10" ] || [ "$OSV1" = "15.04" ] || [ "$OSV11" = "8" ]; then - cp /var/www/html/index.html /var/www/index.html - mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/000-default.conf.ORI - rm -f /etc/apache2/sites-available/000-default.conf - cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/000-default.conf - perl -pi -e "s/http\:\/\/.*\/rutorrent/http\:\/\/$IPADDRESS1\/rutorrent/g" /etc/apache2/sites-available/000-default.conf - perl -pi -e "s//$IPADDRESS1/g" /etc/apache2/sites-available/000-default.conf - perl -pi -e "s//$NEWUSER1/g" /etc/apache2/sites-available/000-default.conf -else - mv /etc/apache2/sites-available/default /etc/apache2/sites-available/default.ORI - rm -f /etc/apache2/sites-available/default - cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/default - perl -pi -e "s/http\:\/\/.*\/rutorrent/http\:\/\/$IPADDRESS1\/rutorrent/g" /etc/apache2/sites-available/default - perl -pi -e "s//$IPADDRESS1/g" /etc/apache2/sites-available/default - perl -pi -e "s//$NEWUSER1/g" /etc/apache2/sites-available/default -fi -#mv /etc/apache2/sites-available/default /etc/apache2/sites-available/default.ORI -#rm -f /etc/apache2/sites-available/default -#cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/default -#perl -pi -e "s/http\:\/\/.*\/rutorrent/http\:\/\/$IPADDRESS1\/rutorrent/g" /etc/apache2/sites-available/default -#perl -pi -e "s//$IPADDRESS1/g" /etc/apache2/sites-available/default -#perl -pi -e "s//$NEWUSER1/g" /etc/apache2/sites-available/default - -echo "ServerName $IPADDRESS1" | tee -a /etc/apache2/apache2.conf > /dev/null - -# 14. -a2ensite default-ssl -#ln -s /etc/apache2/mods-available/scgi.load /etc/apache2/mods-enabled/scgi.load -#service apache2 restart -#apt-get --yes install libxmlrpc-core-c3-dev - -#14.1 Download xmlrpc, rtorrent & libtorrent for 0.9.4 -#cd -#svn co https://svn.code.sf.net/p/xmlrpc-c/code/stable /etc/seedbox-from-scratch/source/xmlrpc -cd /etc/seedbox-from-scratch/ -#wget -c http://libtorrent.rakshasa.no/downloads/rtorrent-0.9.4.tar.gz -#wget -c http://libtorrent.rakshasa.no/downloads/libtorrent-0.13.4.tar.gz -wget -c http://pkgs.fedoraproject.org/repo/pkgs/rtorrent/rtorrent-0.9.4.tar.gz/fd9490a2ac67d0fa2a567c6267845876/rtorrent-0.9.4.tar.gz >> $logfile 2>&1 -wget -c http://pkgs.fedoraproject.org/repo/pkgs/libtorrent/libtorrent-0.13.4.tar.gz/e82f380a9d4b55b379e0e73339c73895/libtorrent-0.13.4.tar.gz >> $logfile 2>&1 - -#configure & make xmlrpc BASED ON RTORRENT VERSION -if [ "$RTORRENT1" = "0.9.4" ]; then - tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.33.17.tgz -C /etc/seedbox-from-scratch/ >> $logfile 2>&1 - cd /etc/seedbox-from-scratch/xmlrpc-c-1.33.17 - ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 - make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 - make install >> $logfile 2>&1 -else - tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.16.42.tgz -C /etc/seedbox-from-scratch/source/ >> $logfile 2>&1 - cd /etc/seedbox-from-scratch/source/ - unzip ../xmlrpc-c-1.31.06.zip >> $logfile 2>&1 - cd xmlrpc-c-1.31.06 - ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 - make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 - make install >> $logfile 2>&1 -fi -# 15. - - -# 16. -#cd xmlrpc-c-1.16.42 ### old, but stable, version, needs a missing old types.h file -#ln -s /usr/include/curl/curl.h /usr/include/curl/types.h - - -# 21. -bash /etc/seedbox-from-scratch/installRTorrent $RTORRENT1 >> $logfile 2>&1 - -######### Below this /var/www/rutorrent/ has been replaced with /var/www/rutorrent for Ubuntu 14.04 - -# 22. -cd /var/www/ -rm -f -r rutorrent -svn checkout https://github.com/Novik/ruTorrent/trunk rutorrent >> $logfile 2>&1 -#svn checkout http://rutorrent.googlecode.com/svn/trunk/plugins -#rm -r -f rutorrent/plugins -#mv plugins rutorrent/ - -cp /etc/seedbox-from-scratch/action.php.template /var/www/rutorrent/plugins/diskspace/action.php - -groupadd admin - -echo "www-data ALL=(root) NOPASSWD: /usr/sbin/repquota" | tee -a /etc/sudoers > /dev/null - -cp /etc/seedbox-from-scratch/favicon.ico /var/www/ - -# 26. Installing Mediainfo from source -apt-get install --yes mediainfo -if [ $? -gt 0 ]; then - cd /tmp - wget http://downloads.sourceforge.net/mediainfo/MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 - tar jxvf MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 - cd MediaInfo_CLI_GNU_FromSource/ - sh CLI_Compile.sh >> $logfile 2>&1 - cd MediaInfo/Project/GNU/CLI - make install >> $logfile 2>&1 -fi - -cd /var/www/rutorrent/js/ -git clone https://github.com/gabceb/jquery-browser-plugin.git >> $logfile 2>&1 -mv jquery-browser-plugin/dist/jquery.browser.js . -rm -r -f jquery-browser-plugin -sed -i '31i\ ' /var/www/rutorrent/index.html - -cd /var/www/rutorrent/plugins -git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi >> $logfile 2>&1 -#cp autodl-irssi/_conf.php autodl-irssi/conf.php -#svn co https://svn.code.sf.net/p/autodl-irssi/code/trunk/rutorrent/autodl-irssi/ -cd autodl-irssi - - -# 30. -cp /etc/jailkit/jk_init.ini /etc/jailkit/jk_init.ini.original -echo "" | tee -a /etc/jailkit/jk_init.ini >> /dev/null -bash /etc/seedbox-from-scratch/updatejkinit - -# 31. ZNC -#Have put this in script form - -# 32. Installing poweroff button on ruTorrent -cd /var/www/rutorrent/plugins/ -wget http://rutorrent-logoff.googlecode.com/files/logoff-1.0.tar.gz >> $logfile 2>&1 -tar -zxf logoff-1.0.tar.gz >> $logfile 2>&1 -rm -f logoff-1.0.tar.gz - -# Installing Filemanager and MediaStream -rm -f -R /var/www/rutorrent/plugins/filemanager -rm -f -R /var/www/rutorrent/plugins/fileupload -rm -f -R /var/www/rutorrent/plugins/mediastream -rm -f -R /var/www/stream - -cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/mediastream >> $logfile 2>&1 - -cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/filemanager >> $logfile 2>&1 - -cp /etc/seedbox-from-scratch/rutorrent.plugins.filemanager.conf.php.template /var/www/rutorrent/plugins/filemanager/conf.php - -mkdir -p /var/www/stream/ -ln -s /var/www/rutorrent/plugins/mediastream/view.php /var/www/stream/view.php -chown www-data: /var/www/stream -chown www-data: /var/www/stream/view.php - -echo "" | tee /var/www/rutorrent/plugins/mediastream/conf.php > /dev/null - -# 32.2 # FILEUPLOAD -cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileupload >> $logfile 2>&1 -chmod 775 /var/www/rutorrent/plugins/fileupload/scripts/upload -apt-get --yes -f install >> $logfile 2>&1 -rm /var/www/rutorrent/plugins/unpack/conf.php -# 32.2 -chown -R www-data:www-data /var/www/rutorrent -chmod -R 755 /var/www/rutorrent - -#32.3 -perl -pi -e "s/\\\$topDirectory\, \\\$fm/\\\$homeDirectory\, \\\$topDirectory\, \\\$fm/g" /var/www/rutorrent/plugins/filemanager/flm.class.php -perl -pi -e "s/\\\$this\-\>userdir \= addslash\(\\\$topDirectory\)\;/\\\$this\-\>userdir \= \\\$homeDirectory \? addslash\(\\\$homeDirectory\) \: addslash\(\\\$topDirectory\)\;/g" /var/www/rutorrent/plugins/filemanager/flm.class.php -perl -pi -e "s/\\\$topDirectory/\\\$homeDirectory/g" /var/www/rutorrent/plugins/filemanager/settings.js.php - -#32.4 -#unzip /etc/seedbox-from-scratch/rutorrent-oblivion.zip -d /var/www/rutorrent/plugins/ -#echo "" | tee -a /var/www/rutorrent/css/style.css > /dev/null -#echo "/* for Oblivion */" | tee -a /var/www/rutorrent/css/style.css > /dev/null -#echo ".meter-value-start-color { background-color: #E05400 }" | tee -a /var/www/rutorrent/css/style.css > /dev/null -#echo ".meter-value-end-color { background-color: #8FBC00 }" | tee -a /var/www/rutorrent/css/style.css > /dev/null -#echo "::-webkit-scrollbar {width:12px;height:12px;padding:0px;margin:0px;}" | tee -a /var/www/rutorrent/css/style.css > /dev/null -perl -pi -e "s/\$defaultTheme \= \"\"\;/\$defaultTheme \= \"Oblivion\"\;/g" /var/www/rutorrent/plugins/theme/conf.php -git clone https://github.com/InAnimaTe/rutorrent-themes.git /var/www/rutorrent/plugins/theme/themes/Extra >> $logfile 2>&1 -cp -r /var/www/rutorrent/plugins/theme/themes/Extra/OblivionBlue /var/www/rutorrent/plugins/theme/themes/ -cp -r /var/www/rutorrent/plugins/theme/themes/Extra/Agent46 /var/www/rutorrent/plugins/theme/themes/ -rm -r /var/www/rutorrent/plugins/theme/themes/Extra -#ln -s /etc/seedbox-from-scratch/seedboxInfo.php.template /var/www/seedboxInfo.php - -# 32.5 -cd /var/www/rutorrent/plugins/ -rm -r /var/www/rutorrent/plugins/fileshare -rm -r /var/www/share -svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileshare >> $logfile 2>&1 -mkdir /var/www/share -ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/share.php -ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/index.php -chown -R www-data:www-data /var/www/share -cp /etc/seedbox-from-scratch/rutorrent.plugins.fileshare.conf.php.template /var/www/rutorrent/plugins/fileshare/conf.php -perl -pi -e "s//$IPADDRESS1/g" /var/www/rutorrent/plugins/fileshare/conf.php - -mv /etc/seedbox-from-scratch/unpack.conf.php /var/www/rutorrent/plugins/unpack/conf.php - -# 33. -bash /etc/seedbox-from-scratch/updateExecutables >> $logfile 2>&1 - -#34. -echo $SBFSCURRENTVERSION1 > /etc/seedbox-from-scratch/version.info -echo $NEWFTPPORT1 > /etc/seedbox-from-scratch/ftp.info -echo $NEWSSHPORT1 > /etc/seedbox-from-scratch/ssh.info -echo $OPENVPNPORT1 > /etc/seedbox-from-scratch/openvpn.info - -# 36. -wget -P /usr/share/ca-certificates/ --no-check-certificate https://certs.godaddy.com/repository/gd_intermediate.crt https://certs.godaddy.com/repository/gd_cross_intermediate.crt -update-ca-certificates -c_rehash - -# 96. -if [ "$INSTALLOPENVPN1" = "YES" ]; then - bash /etc/seedbox-from-scratch/installOpenVPN -fi - -if [ "$INSTALLSABNZBD1" = "YES" ]; then - bash /etc/seedbox-from-scratch/installSABnzbd -fi - -if [ "$INSTALLRAPIDLEECH1" = "YES" ]; then - bash /etc/seedbox-from-scratch/installRapidleech -fi - -if [ "$INSTALLDELUGE1" = "YES" ]; then - bash /etc/seedbox-from-scratch/installDeluge -fi - -# 97. First user will not be jailed -# createSeedboxUser -bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO >> $logfile 2>&1 - -#Sickrage -sudo apt-get install python-cheetah python -sudo apt-get install git -sudo git clone https://github.com/SiCKRAGETV/SickRage.git /opt/SickRage -sudo wget http://cheapseedboxes.com/sickrage -P /etc/init.d/ -sudo chmod +x /etc/init.d/sickrage -sudo wget http://cheapseedboxes.com/csickrage -P /etc/default/ -sudo update-rc.d sickrage defaults -sudo service sickrage start - - -#Subsonic -sudo apt-get install openjdk-7-jre -wget http://subsonic.org/download/subsonic-5.2.1.deb -sudo dpkg -i subsonic-5.2.1.deb -sudo chmod -R 755 /etc/default/subsonic -sudo perl -pi -e "s/$NEWUSER1o=root/SUBSONIC_USER=$NEWUSER1/g" /etc/default/subsonic -sudo service subsonic restart - - - -#Loadavg -cd ~ -git clone https://github.com/loadavg/loadavg.git -cd loadavg -cd ~ -mv loadavg /var/www/ - - - -# 98. Cosmetic corrections & installing plowshare -#cd /var/www/rutorrent/plugins/autodl-irssi -#rm AutodlFilesDownloader.js -#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/AutodlFilesDownloader.js -#cd /var/www/rutorrent/js -#rm webui.js -#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/webui.js -cd /var/www -chown -R www-data:www-data /var/www/rutorrent -chmod -R 755 /var/www/rutorrent -cd -git clone https://github.com/mcrapet/plowshare.git plowshare -cd ~/plowshare -make install -cd -rm -r plowshare - -if [ "$OS1" = "Debian" ]; then - apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd -fi - -export EDITOR=nano -# 100 -cd /var/www/rutorrent/plugins -sleep 1 -rm -frv diskspace -wget --no-check-certificate https://bintray.com/artifact/download/hectortheone/base/pool/main/b/base/hectortheone.rar -#wget http://dl.bintray.com/novik65/generi...ace-3.6.tar.gz -#tar -xf diskspace-3.6.tar.gz -unrar x hectortheone.rar -#rm diskspace-3.6.tar.gz -rm hectortheone.rar -cd quotaspace -chmod 755 run.sh -cd .. -wget --no-check-certificate http://cheapseedboxes.com/trafic_check.rar -unrar x trafic_check.rar -rm trafic_check.rar -wget --no-check-certificate http://cheapseedboxes.com/plimits.rar -unrar x plimits.rar -rm plimits.rar -cd .. -chown -R www-data:www-data /var/www/rutorrent -set +x verbose -cd / -cd ~/ -wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb -sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb -sudo apt-get install -f -rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb - - -clear - - -echo "" -echo "<<< The Seedbox From Scratch Script >>>" -echo "Script Modified by dannyti ---> https://github.com/dannyti/" -echo "" -echo "Looks like everything is set." -echo "" -echo "Remember that your SSH port is now ======> $NEWSSHPORT1" -echo "" -echo "Your Login info can also be found at https://$IPADDRESS1/private/SBinfo.txt" -echo "Download Data Directory is located at https://$IPADDRESS1/private " -echo "" -echo "System will reboot now, but don't close this window until you take note of the port number: $NEWSSHPORT1" -echo "" -echo "" - -reboot - -##################### LAST LINE ########### From 6666cf110b5157877d2d157b6e8810ea97366f1d Mon Sep 17 00:00:00 2001 From: fravia1 Date: Fri, 4 Sep 2015 17:22:54 +0530 Subject: [PATCH 24/32] Create sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 894 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 894 insertions(+) create mode 100644 sbfrmsc-dti.sh diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh new file mode 100644 index 0000000..55c9298 --- /dev/null +++ b/sbfrmsc-dti.sh @@ -0,0 +1,894 @@ +#!/bin/bash + +# Updated for $.broswer-msie error; will populate tracker list properly ; create check/start scripts; +# create crontab entries. Rest is all perfect from Notos. Thanks. +# +# The Seedbox From Scratch Script +# By Notos ---> https://github.com/Notos/ +# Modified by dannyti ---> https://github.com/dannyti/ +# +###################################################################### +# +# Copyright (c) 2013 Notos (https://github.com/Notos/) & dannyti (https://github.com/dannyti/) +# +# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# +# --> Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php +# +###################################################################### +# +# git clone -b master https://github.com/Notos/seedbox-from-scratch.git /etc/seedbox-from-scratch +# sudo git stash; sudo git pull +# +apt-get --yes install lsb-release + SBFSCURRENTVERSION1=14.06 + OS1=$(lsb_release -si) + OSV1=$(lsb_release -rs) + OSV11=$(sed 's/\..*//' /etc/debian_version) + logfile="/dev/null" +# +# Changelog +# Version 14.06 (By dannyti) +# Jan 16 2015 +# - RTorrent 0.9.4 supported +# - Openvpn Fixed and Working +# - Autodl tracker list correctly populated +# - Diskspace fixed for multiuser environment +# - Added http Data Download directory for users ; Can be accessed at http://Server-IP/private/Downloads ; Only http:// +# - Sitewide https only +# - User Login info can be accessed individually at http://Server-IP/private/SBinfo.txt +# - Mediainfo fixed ; installtion from source +# - Jquery Error corrected +# - Crontab entries made for checking rtorrrent is running and starting it if not running +# - Plowshare Fixed +# - Deprecated seedboxInfo.php +# +# Version 2.1.9 (not stable yet) +# Dec 26 2012 17:37 GMT-3 +# - RTorrent 0.9.3 support (optionally installed) +# - New installRTorrent script: move to RTorrent 0.9.3 or back to 0.9.2 at any time +# - Deluge v1.3.6 multi-user installation script (it will install the last stable version): installDeluge +# - Optionally install Deluge when you first install your seedbox-from-scratch box +# +# Version 2.1.8 (stable) +# - Bug fix release +# +# Version 2.1.4 (stable) +# Dec 11 2012 2:34 GMT-3 +# - Debian 6 (Squeeze) Compatibile +# - Check if user root is running the script +# - vsftpd - FTP access with SSL (AUTH SSL - Explicit) +# - vsftpd downgraded on Ubuntu to 2.3.2 (oneiric) +# - iptables tweaked to make OpenVPN work as it should both on Ubuntu and Debian +# - SABnzbd is now being installed from sources and works better +# - New script: changeUserPassword --- example: changeUserPassword notos 133t rutorrent +# - restartSeedbox now kill processes even if there are users attached on screens +# - Installs rar, unrar and zip separately from main installations to prevent script from breaking on bad sources from non-OVH providers +# +# Version 2.1.2 (stable) +# Nov 16 2012 20:48 GMT-3 +# - new upgradeSeedbox script (to download git files for a new version, it will not really upgrade it, at least for now :) +# - ruTorrent fileshare Plugin (http://forums.rutorrent.org/index.php?topic=705.0) +# - rapidleech (http://www.rapidleech.com/ - http://www.rapidleech.com/index.php?showtopic=2226|Go ** tutorial: http://www.seedm8.com/members/knowledgebase/24/Installing-Rapidleech-on-your-Seedbox.html +# +# Version 2.1.1 (stable) +# Nov 12 2012 20:15 +# - OpenVPN was not working as expected (fixed) +# - OpenVPN port now is configurable (at main install) and you can change it anytime before reinstalling: /etc/seedbox-from-scratch/openvpn.info +# +# Version 2.1.0 (not stable yet) +# Nov 11 2012 20:15 +# - sabnzbd: http://wiki.sabnzbd.org/install-ubuntu-repo +# - restartSeedbox script for each user +# - User info files in /etc/seedbox-from-scratch/users +# - Info about all users in https://hostname.tld/seedboxInfo.php +# - Password protected webserver Document Root (/var/www/) +# +# Version 2.0.0 (stable) +# Oct 31 2012 23:59 +# - chroot jail for users, using JailKit (http://olivier.sessink.nl/jailkit/) +# - Fail2ban for ssh and apache - it bans IPs that show the malicious signs -- too many password failures, seeking for exploits, etc. +# - OpenVPN (after install you can download your key from http:///rutorrent/vpn.zip) +# - createSeedboxUser script now asks if you want your user jailed, to have SSH access and if it should be added to sudoers +# - Optionally install packages JailKit, Webmin, Fail2ban and OpenVPN +# - Choose between RTorrent 0.8.9 and 0.9.2 (and their respective libtorrent libraries) +# - Upgrade and downgrade RTorrent at any time +# - Full automated install, now you just have to download script and run it in your box: +# > wget -N https://raw.github.com/Notos/seedbox-from-scratch/v2.x.x/seedbox-from-scratch.sh +# > time bash ~/seedbox-from-scratch.sh +# - Due to a recent outage of Webmin site and SourceForge's svn repositories, some packages are now in git and will not be downloaded from those sites +# - Updated list of trackers in Autodl-irssi +# - vsftpd FTP Server (working in chroot jail) +# - New ruTorrent default theme: Oblivion +# +# Version 1.30 +# Oct 23 2012 04:54:29 +# - Scripts now accept a full install without having to create variables and do anything else +# +# Version 1.20 +# Oct 19 2012 03:24 (by Notos) +# - Install OpenVPN - (BETA) Still not in the script, just an outside script +# Tested client: http://openvpn.net/index.php?option=com_content&id=357 +# +# Version 1.11 +# Oct 18 2012 05:13 (by Notos) +# - Added scripts to downgrade and upgrade RTorrent +# +# - Added all supported plowshare sites into fileupload plugin: 115, 1fichier, 2shared, 4shared, bayfiles, bitshare, config, cramit, data_hu, dataport_cz, +# depositfiles, divshare, dl_free_fr, euroshare_eu, extabit, filebox, filemates, filepost, freakshare, go4up, hotfile, mediafire, megashares, mirrorcreator, multiupload, netload_in, +# oron, putlocker, rapidgator, rapidshare, ryushare, sendspace, shareonline_biz, turbobit, uploaded_net, uploadhero, uploading, uptobox, zalaa, zippyshare +# +# Version 1.10 +# 06/10/2012 14:18 (by Notos) +# - Added Fileupload plugin +# +# - Added all supported plowshare sites into fileupload plugin: 115, 1fichier, 2shared, 4shared, bayfiles, bitshare, config, cramit, data_hu, dataport_cz, +# depositfiles, divshare, dl_free_fr, euroshare_eu, extabit, filebox, filemates, filepost, freakshare, go4up, hotfile, mediafire, megashares, mirrorcreator, multiupload, netload_in, +# oron, putlocker, rapidgator, rapidshare, ryushare, sendspace, shareonline_biz, turbobit, uploaded_net, uploadhero, uploading, uptobox, zalaa, zippyshare +# +# Version 1.00 +# 30/09/2012 14:18 (by Notos) +# - Changing some file names and depoying version 1.00 +# +# Version 0.99b +# 27/09/2012 19:39 (by Notos) +# - Quota for users +# - Download dir inside user home +# +# Version 0.99a +# 27/09/2012 19:39 (by Notos) +# - Quota for users +# - Download dir inside user home +# +# Version 0.92a +# 28/08/2012 19:39 (by Notos) +# - Also working on Debian now +# +# Version 0.91a +# 24/08/2012 19:39 (by Notos) +# - First multi-user version sent to public +# +# Version 0.90a +# 22/08/2012 19:39 (by Notos) +# - Working version for OVH Kimsufi 2G Server - Ubuntu Based +# +# Version 0.89a +# 17/08/2012 19:39 (by Notos) +# +function getString +{ + local ISPASSWORD=$1 + local LABEL=$2 + local RETURN=$3 + local DEFAULT=$4 + local NEWVAR1=a + local NEWVAR2=b + local YESYES=YESyes + local NONO=NOno + local YESNO=$YESYES$NONO + + while [ ! $NEWVAR1 = $NEWVAR2 ] || [ -z "$NEWVAR1" ]; + do + clear + echo "#" + echo "#" + echo "# The Seedbox From Scratch Script" + echo "# By Notos ---> https://github.com/Notos/" + echo "# Modified by dannyti ---> https://github.com/dannyti/" + echo "#" + echo "#" + echo + + if [ "$ISPASSWORD" == "YES" ]; then + read -s -p "$DEFAULT" -p "$LABEL" NEWVAR1 + else + read -e -i "$DEFAULT" -p "$LABEL" NEWVAR1 + fi + if [ -z "$NEWVAR1" ]; then + NEWVAR1=a + continue + fi + + if [ ! -z "$DEFAULT" ]; then + if grep -q "$DEFAULT" <<< "$YESNO"; then + if grep -q "$NEWVAR1" <<< "$YESNO"; then + if grep -q "$NEWVAR1" <<< "$YESYES"; then + NEWVAR1=YES + else + NEWVAR1=NO + fi + else + NEWVAR1=a + fi + fi + fi + + if [ "$NEWVAR1" == "$DEFAULT" ]; then + NEWVAR2=$NEWVAR1 + else + if [ "$ISPASSWORD" == "YES" ]; then + echo + read -s -p "Retype: " NEWVAR2 + else + read -p "Retype: " NEWVAR2 + fi + if [ -z "$NEWVAR2" ]; then + NEWVAR2=b + continue + fi + fi + + + if [ ! -z "$DEFAULT" ]; then + if grep -q "$DEFAULT" <<< "$YESNO"; then + if grep -q "$NEWVAR2" <<< "$YESNO"; then + if grep -q "$NEWVAR2" <<< "$YESYES"; then + NEWVAR2=YES + else + NEWVAR2=NO + fi + else + NEWVAR2=a + fi + fi + fi + echo "---> $NEWVAR2" + + done + eval $RETURN=\$NEWVAR1 +} +# 0. + +if [[ $EUID -ne 0 ]]; then + echo "This script must be run as root" 1>&2 + exit 1 +fi + +export DEBIAN_FRONTEND=noninteractive + +clear + +# 1. + +#localhost is ok this rtorrent/rutorrent installation +IPADDRESS1=`ifconfig | sed -n 's/.*inet addr:\([0-9.]\+\)\s.*/\1/p' | grep -v 127 | head -n 1` +CHROOTJAIL1=NO + +#those passwords will be changed in the next steps +PASSWORD1=a +PASSWORD2=b + +getString NO "You need to create an user for your seedbox: " NEWUSER1 +getString YES "Password for user $NEWUSER1: " PASSWORD1 +getString NO "IP address of your box: " IPADDRESS1 $IPADDRESS1 +getString NO "SSH port: " NEWSSHPORT1 21976 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 21201 +getString NO "OpenVPN port: " OPENVPNPORT1 31195 +#getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES +getString NO "Install Webmin? " INSTALLWEBMIN1 YES +getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES +getString NO "Install OpenVPN? " INSTALLOPENVPN1 NO +getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO +getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO +getString NO "Install Deluge? " INSTALLDELUGE1 NO +getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 + +if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then + echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" + exit 1 +fi + +if [ "$OSV1" = "14.04" ]; then + apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5 + apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32 +fi +echo "........" +echo "............." +echo "Work in Progres.......... " +echo "Please Standby................ " +apt-get --yes update >> $logfile 2>&1 +apt-get --yes install whois sudo makepasswd git nano >> $logfile 2>&1 + +rm -f -r /etc/seedbox-from-scratch +git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch >> $logfile 2>&1 +mkdir -p cd /etc/seedbox-from-scratch/source +mkdir -p cd /etc/seedbox-from-scratch/users + +if [ ! -f /etc/seedbox-from-scratch/seedbox-from-scratch.sh ]; then + clear + echo Looks like something is wrong, this script was not able to download its whole git repository. + set -e + exit 1 +fi + +# 3.1 + +#show all commands +set -x verbose + +# 4. +perl -pi -e "s/Port 22/Port $NEWSSHPORT1/g" /etc/ssh/sshd_config +perl -pi -e "s/PermitRootLogin yes/PermitRootLogin no/g" /etc/ssh/sshd_config +perl -pi -e "s/#Protocol 2/Protocol 2/g" /etc/ssh/sshd_config +perl -pi -e "s/X11Forwarding yes/X11Forwarding no/g" /etc/ssh/sshd_config + +groupadd sshdusers +groupadd sftponly + +mkdir -p /usr/share/terminfo/l/ +cp /lib/terminfo/l/linux /usr/share/terminfo/l/ +#echo '/usr/lib/openssh/sftp-server' >> /etc/shells +if [ "$OS1" = "Ubuntu" ]; then + echo "" | tee -a /etc/ssh/sshd_config > /dev/null + echo "UseDNS no" | tee -a /etc/ssh/sshd_config > /dev/null + echo "AllowGroups sshdusers root" >> /etc/ssh/sshd_config + echo "Match Group sftponly" >> /etc/ssh/sshd_config + echo "ChrootDirectory %h" >> /etc/ssh/sshd_config + echo "ForceCommand internal-sftp" >> /etc/ssh/sshd_config + echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config +fi + +service ssh reload + +# 6. +#remove cdrom from apt so it doesn't stop asking for it +perl -pi -e "s/deb cdrom/#deb cdrom/g" /etc/apt/sources.list +perl -pi.orig -e 's/^(deb .* universe)$/$1 multiverse/' /etc/apt/sources.list +#add non-free sources to Debian Squeeze# those two spaces below are on purpose +perl -pi -e "s/squeeze main/squeeze main contrib non-free/g" /etc/apt/sources.list +perl -pi -e "s/squeeze-updates main/squeeze-updates main contrib non-free/g" /etc/apt/sources.list + +#apt-get --yes install python-software-properties +#Adding debian pkgs for adding repo and installing ffmpeg +apt-get --yes install software-properties-common +if [ "$OSV11" = "8" ]; then + apt-add-repository --yes "deb http://www.deb-multimedia.org jessie main non-free" + apt-get update >> $logfile 2>&1 + apt-get --force-yes --yes install ffmpeg >> $logfile 2>&1 +fi + +# 7. +# update and upgrade packages +apt-get --yes install python-software-properties software-properties-common +if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "15.04" ] || [ "$OSV1" = "14.10" ]; then + apt-add-repository --yes ppa:kirillshkrogalev/ffmpeg-next +fi +apt-get --yes update >> $logfile 2>&1 +apt-get --yes upgrade >> $logfile 2>&1 +# 8. +#install all needed packages +apt-get --yes install apache2 apache2-utils autoconf build-essential ca-certificates comerr-dev curl cfv quota mktorrent dtach htop irssi libapache2-mod-php5 libcloog-ppl-dev libcppunit-dev libcurl3 libcurl4-openssl-dev libncurses5-dev libterm-readline-gnu-perl libsigc++-2.0-dev libperl-dev openvpn libssl-dev libtool libxml2-dev ncurses-base ncurses-term ntp openssl patch libc-ares-dev pkg-config php5 php5-cli php5-dev php5-curl php5-geoip php5-mcrypt php5-gd php5-xmlrpc pkg-config python-scgi screen ssl-cert subversion texinfo unzip zlib1g-dev expect flex bison debhelper binutils-gold libarchive-zip-perl libnet-ssleay-perl libhtml-parser-perl libxml-libxml-perl libjson-perl libjson-xs-perl libxml-libxslt-perl libxml-libxml-perl libjson-rpc-perl libarchive-zip-perl tcpdump >> $logfile 2>&1 +if [ $? -gt 0 ]; then + set +x verbose + echo + echo + echo *** ERROR *** + echo + echo "Looks like something is wrong with apt-get install, aborting." + echo + echo + echo + set -e + exit 1 +fi +apt-get --yes install zip >> $logfile 2>&1 + +apt-get --yes install ffmpeg >> $logfile 2>&1 +apt-get --yes install automake1.9 + +apt-get --force-yes --yes install rar +if [ $? -gt 0 ]; then + apt-get --yes install rar-free +fi + +apt-get --yes install unrar +if [ $? -gt 0 ]; then + apt-get --yes install unrar-free +fi +if [ "$OSV1" = "8.1" ]; then + apt-get --yes install unrar-free +fi + +apt-get --yes install dnsutils + +if [ "$CHROOTJAIL1" = "YES" ]; then + cd /etc/seedbox-from-scratch + tar xvfz jailkit-2.15.tar.gz -C /etc/seedbox-from-scratch/source/ + cd source/jailkit-2.15 + ./debian/rules binary + cd .. + dpkg -i jailkit_2.15-1_*.deb +fi + +# 8.1 additional packages for Ubuntu +# this is better to be apart from the others +apt-get --yes install php5-fpm >> $logfile 2>&1 +apt-get --yes install php5-xcache libxml2-dev >> $logfile 2>&1 + +if [ "$OSV1" = "13.10" ]; then + apt-get install php5-json +fi + +#Check if its Debian and do a sysvinit by upstart replacement: +#Commented the follwoing three lines for testing +#if [ "$OS1" = "Debian" ]; then +# echo 'Yes, do as I say!' | apt-get -y --force-yes install upstart +#fi + +# 8.3 Generate our lists of ports and RPC and create variables + +#permanently adding scripts to PATH to all users and root +echo "PATH=$PATH:/etc/seedbox-from-scratch:/sbin" | tee -a /etc/profile > /dev/null +echo "export PATH" | tee -a /etc/profile > /dev/null +echo "PATH=$PATH:/etc/seedbox-from-scratch:/sbin" | tee -a /root/.bashrc > /dev/null +echo "export PATH" | tee -a /root/.bashrc > /dev/null + +rm -f /etc/seedbox-from-scratch/ports.txt +for i in $(seq 51101 51999) +do + echo "$i" | tee -a /etc/seedbox-from-scratch/ports.txt > /dev/null +done + +rm -f /etc/seedbox-from-scratch/rpc.txt +for i in $(seq 2 1000) +do + echo "RPC$i" | tee -a /etc/seedbox-from-scratch/rpc.txt > /dev/null +done + +# 8.4 + +if [ "$INSTALLWEBMIN1" = "YES" ]; then + #if webmin isup, download key + WEBMINDOWN=YES + ping -c1 -w2 www.webmin.com > /dev/null + if [ $? = 0 ] ; then + wget -t 5 http://www.webmin.com/jcameron-key.asc + apt-key add jcameron-key.asc + if [ $? = 0 ] ; then + WEBMINDOWN=NO + fi + fi + + if [ "$WEBMINDOWN"="NO" ] ; then + #add webmin source + echo "" | tee -a /etc/apt/sources.list > /dev/null + echo "deb http://download.webmin.com/download/repository sarge contrib" | tee -a /etc/apt/sources.list > /dev/null + cd /tmp + fi + + if [ "$WEBMINDOWN" = "NO" ]; then + apt-get --yes update >> $logfile 2>&1 + apt-get --yes install webmin >> $logfile 2>&1 + fi +fi + +if [ "$INSTALLFAIL2BAN1" = "YES" ]; then + apt-get --yes install fail2ban >> $logfile 2>&1 + cp /etc/fail2ban/jail.conf /etc/fail2ban/jail.conf.original + cp /etc/seedbox-from-scratch/etc.fail2ban.jail.conf.template /etc/fail2ban/jail.conf + fail2ban-client reload +fi + +# 9. +a2enmod ssl +a2enmod auth_digest +a2enmod reqtimeout +a2enmod rewrite +#a2enmod scgi ############### if we cant make python-scgi works +#cd /etc/apache2 +#rm apache2.conf +#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/apache2.conf +cat /etc/seedbox-from-scratch/add2apache2.conf >> /etc/apache2/apache2.conf +# 10. + +#remove timeout if there are any +perl -pi -e "s/^Timeout [0-9]*$//g" /etc/apache2/apache2.conf + +echo "" | tee -a /etc/apache2/apache2.conf > /dev/null +echo "#seedbox values" | tee -a /etc/apache2/apache2.conf > /dev/null +echo "" | tee -a /etc/apache2/apache2.conf > /dev/null +echo "" | tee -a /etc/apache2/apache2.conf > /dev/null +echo "ServerSignature Off" | tee -a /etc/apache2/apache2.conf > /dev/null +echo "ServerTokens Prod" | tee -a /etc/apache2/apache2.conf > /dev/null +echo "Timeout 30" | tee -a /etc/apache2/apache2.conf > /dev/null +cd /etc/apache2 +rm ports.conf +wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf >> $logfile 2>&1 +service apache2 restart +mkdir /etc/apache2/auth.users + +echo "$IPADDRESS1" > /etc/seedbox-from-scratch/hostname.info + +# 11. + +export TEMPHOSTNAME1=tsfsSeedBox +export CERTPASS1=@@$TEMPHOSTNAME1.$NEWUSER1.ServerP7s$ +export NEWUSER1 +export IPADDRESS1 + +echo "$NEWUSER1" > /etc/seedbox-from-scratch/mainuser.info +echo "$CERTPASS1" > /etc/seedbox-from-scratch/certpass.info + +bash /etc/seedbox-from-scratch/createOpenSSLCACertificate + +mkdir -p /etc/ssl/private/ +openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout /etc/ssl/private/vsftpd.pem -out /etc/ssl/private/vsftpd.pem -config /etc/seedbox-from-scratch/ssl/CA/caconfig.cnf + +if [ "$OSV11" = "7" ]; then + echo "deb http://ftp.cyconet.org/debian wheezy-updates main non-free contrib" >> /etc/apt/sources.list.d/wheezy-updates.cyconet.list + apt-get update + apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd libxml2-dev libcurl4-gnutls-dev subversion >> $logfile 2>&1 +elif [ "$OSV1" = "12.04" ]; then + add-apt-repository -y ppa:thefrontiergroup/vsftpd + apt-get update + apt-get -y install vsftpd +else + apt-get -y install vsftpd +fi + + +#if [ "$OSV1" = "12.04" ]; then +# dpkg -i /etc/seedbox-from-scratch/vsftpd_2.3.2-3ubuntu5.1_`uname -m`.deb +#fi + +perl -pi -e "s/anonymous_enable\=YES/\#anonymous_enable\=YES/g" /etc/vsftpd.conf +perl -pi -e "s/connect_from_port_20\=YES/#connect_from_port_20\=YES/g" /etc/vsftpd.conf +perl -pi -e 's/rsa_private_key_file/#rsa_private_key_file/' /etc/vsftpd.conf +perl -pi -e 's/rsa_cert_file/#rsa_cert_file/' /etc/vsftpd.conf +#perl -pi -e "s/rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem/#rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem/g" /etc/vsftpd.conf +#perl -pi -e "s/rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key/#rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key/g" /etc/vsftpd.conf +echo "listen_port=$NEWFTPPORT1" | tee -a /etc/vsftpd.conf >> /dev/null +echo "ssl_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "allow_anon_ssl=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "force_local_data_ssl=NO" | tee -a /etc/vsftpd.conf >> /dev/null +echo "force_local_logins_ssl=NO" | tee -a /etc/vsftpd.conf >> /dev/null +echo "ssl_tlsv1=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "ssl_sslv2=NO" | tee -a /etc/vsftpd.conf >> /dev/null +echo "ssl_sslv3=NO" | tee -a /etc/vsftpd.conf >> /dev/null +echo "require_ssl_reuse=NO" | tee -a /etc/vsftpd.conf >> /dev/null +echo "ssl_ciphers=HIGH" | tee -a /etc/vsftpd.conf >> /dev/null +echo "rsa_cert_file=/etc/ssl/private/vsftpd.pem" | tee -a /etc/vsftpd.conf >> /dev/null +echo "local_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "write_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "local_umask=022" | tee -a /etc/vsftpd.conf >> /dev/null +echo "chroot_local_user=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "chroot_list_file=/etc/vsftpd.chroot_list" | tee -a /etc/vsftpd.conf >> /dev/null +echo "passwd_chroot_enable=YES" | tee -a /etc/vsftpd.conf >> /dev/null +echo "allow_writeable_chroot=YES" | tee -a /etc/vsftpd.conf >> /dev/null +#sed -i '147 d' /etc/vsftpd.conf +#sed -i '149 d' /etc/vsftpd.conf + +apt-get install --yes subversion >> $logfile 2>&1 +apt-get install --yes dialog >> $logfile 2>&1 +# 13. + +if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "14.10" ] || [ "$OSV1" = "15.04" ] || [ "$OSV11" = "8" ]; then + cp /var/www/html/index.html /var/www/index.html + mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/000-default.conf.ORI + rm -f /etc/apache2/sites-available/000-default.conf + cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/000-default.conf + perl -pi -e "s/http\:\/\/.*\/rutorrent/http\:\/\/$IPADDRESS1\/rutorrent/g" /etc/apache2/sites-available/000-default.conf + perl -pi -e "s//$IPADDRESS1/g" /etc/apache2/sites-available/000-default.conf + perl -pi -e "s//$NEWUSER1/g" /etc/apache2/sites-available/000-default.conf +else + mv /etc/apache2/sites-available/default /etc/apache2/sites-available/default.ORI + rm -f /etc/apache2/sites-available/default + cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/default + perl -pi -e "s/http\:\/\/.*\/rutorrent/http\:\/\/$IPADDRESS1\/rutorrent/g" /etc/apache2/sites-available/default + perl -pi -e "s//$IPADDRESS1/g" /etc/apache2/sites-available/default + perl -pi -e "s//$NEWUSER1/g" /etc/apache2/sites-available/default +fi +#mv /etc/apache2/sites-available/default /etc/apache2/sites-available/default.ORI +#rm -f /etc/apache2/sites-available/default +#cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/default +#perl -pi -e "s/http\:\/\/.*\/rutorrent/http\:\/\/$IPADDRESS1\/rutorrent/g" /etc/apache2/sites-available/default +#perl -pi -e "s//$IPADDRESS1/g" /etc/apache2/sites-available/default +#perl -pi -e "s//$NEWUSER1/g" /etc/apache2/sites-available/default + +echo "ServerName $IPADDRESS1" | tee -a /etc/apache2/apache2.conf > /dev/null + +# 14. +a2ensite default-ssl +#ln -s /etc/apache2/mods-available/scgi.load /etc/apache2/mods-enabled/scgi.load +#service apache2 restart +#apt-get --yes install libxmlrpc-core-c3-dev + +#14.1 Download xmlrpc, rtorrent & libtorrent for 0.9.4 +#cd +#svn co https://svn.code.sf.net/p/xmlrpc-c/code/stable /etc/seedbox-from-scratch/source/xmlrpc +cd /etc/seedbox-from-scratch/ +#wget -c http://libtorrent.rakshasa.no/downloads/rtorrent-0.9.4.tar.gz +#wget -c http://libtorrent.rakshasa.no/downloads/libtorrent-0.13.4.tar.gz +wget -c http://pkgs.fedoraproject.org/repo/pkgs/rtorrent/rtorrent-0.9.4.tar.gz/fd9490a2ac67d0fa2a567c6267845876/rtorrent-0.9.4.tar.gz >> $logfile 2>&1 +wget -c http://pkgs.fedoraproject.org/repo/pkgs/libtorrent/libtorrent-0.13.4.tar.gz/e82f380a9d4b55b379e0e73339c73895/libtorrent-0.13.4.tar.gz >> $logfile 2>&1 + +#configure & make xmlrpc BASED ON RTORRENT VERSION +if [ "$RTORRENT1" = "0.9.4" ]; then + tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.33.17.tgz -C /etc/seedbox-from-scratch/ >> $logfile 2>&1 + cd /etc/seedbox-from-scratch/xmlrpc-c-1.33.17 + ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 + make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 + make install >> $logfile 2>&1 +else + tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.16.42.tgz -C /etc/seedbox-from-scratch/source/ >> $logfile 2>&1 + cd /etc/seedbox-from-scratch/source/ + unzip ../xmlrpc-c-1.31.06.zip >> $logfile 2>&1 + cd xmlrpc-c-1.31.06 + ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 + make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 + make install >> $logfile 2>&1 +fi +# 15. + + +# 16. +#cd xmlrpc-c-1.16.42 ### old, but stable, version, needs a missing old types.h file +#ln -s /usr/include/curl/curl.h /usr/include/curl/types.h + + +# 21. +bash /etc/seedbox-from-scratch/installRTorrent $RTORRENT1 >> $logfile 2>&1 + +######### Below this /var/www/rutorrent/ has been replaced with /var/www/rutorrent for Ubuntu 14.04 + +# 22. +cd /var/www/ +rm -f -r rutorrent +svn checkout https://github.com/Novik/ruTorrent/trunk rutorrent >> $logfile 2>&1 +#svn checkout http://rutorrent.googlecode.com/svn/trunk/plugins +#rm -r -f rutorrent/plugins +#mv plugins rutorrent/ + +cp /etc/seedbox-from-scratch/action.php.template /var/www/rutorrent/plugins/diskspace/action.php + +groupadd admin + +echo "www-data ALL=(root) NOPASSWD: /usr/sbin/repquota" | tee -a /etc/sudoers > /dev/null + +cp /etc/seedbox-from-scratch/favicon.ico /var/www/ + +# 26. Installing Mediainfo from source +apt-get install --yes mediainfo +if [ $? -gt 0 ]; then + cd /tmp + wget http://downloads.sourceforge.net/mediainfo/MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 + tar jxvf MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 + cd MediaInfo_CLI_GNU_FromSource/ + sh CLI_Compile.sh >> $logfile 2>&1 + cd MediaInfo/Project/GNU/CLI + make install >> $logfile 2>&1 +fi + +cd /var/www/rutorrent/js/ +git clone https://github.com/gabceb/jquery-browser-plugin.git >> $logfile 2>&1 +mv jquery-browser-plugin/dist/jquery.browser.js . +rm -r -f jquery-browser-plugin +sed -i '31i\ ' /var/www/rutorrent/index.html + +cd /var/www/rutorrent/plugins +git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi >> $logfile 2>&1 +#cp autodl-irssi/_conf.php autodl-irssi/conf.php +#svn co https://svn.code.sf.net/p/autodl-irssi/code/trunk/rutorrent/autodl-irssi/ +cd autodl-irssi + + +# 30. +cp /etc/jailkit/jk_init.ini /etc/jailkit/jk_init.ini.original +echo "" | tee -a /etc/jailkit/jk_init.ini >> /dev/null +bash /etc/seedbox-from-scratch/updatejkinit + +# 31. ZNC +#Have put this in script form + +# 32. Installing poweroff button on ruTorrent +cd /var/www/rutorrent/plugins/ +wget http://rutorrent-logoff.googlecode.com/files/logoff-1.0.tar.gz >> $logfile 2>&1 +tar -zxf logoff-1.0.tar.gz >> $logfile 2>&1 +rm -f logoff-1.0.tar.gz + +# Installing Filemanager and MediaStream +rm -f -R /var/www/rutorrent/plugins/filemanager +rm -f -R /var/www/rutorrent/plugins/fileupload +rm -f -R /var/www/rutorrent/plugins/mediastream +rm -f -R /var/www/stream + +cd /var/www/rutorrent/plugins/ +svn co http://svn.rutorrent.org/svn/filemanager/trunk/mediastream >> $logfile 2>&1 + +cd /var/www/rutorrent/plugins/ +svn co http://svn.rutorrent.org/svn/filemanager/trunk/filemanager >> $logfile 2>&1 + +cp /etc/seedbox-from-scratch/rutorrent.plugins.filemanager.conf.php.template /var/www/rutorrent/plugins/filemanager/conf.php + +mkdir -p /var/www/stream/ +ln -s /var/www/rutorrent/plugins/mediastream/view.php /var/www/stream/view.php +chown www-data: /var/www/stream +chown www-data: /var/www/stream/view.php + +echo "" | tee /var/www/rutorrent/plugins/mediastream/conf.php > /dev/null + +# 32.2 # FILEUPLOAD +cd /var/www/rutorrent/plugins/ +svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileupload >> $logfile 2>&1 +chmod 775 /var/www/rutorrent/plugins/fileupload/scripts/upload +apt-get --yes -f install >> $logfile 2>&1 +rm /var/www/rutorrent/plugins/unpack/conf.php +# 32.2 +chown -R www-data:www-data /var/www/rutorrent +chmod -R 755 /var/www/rutorrent + +#32.3 +perl -pi -e "s/\\\$topDirectory\, \\\$fm/\\\$homeDirectory\, \\\$topDirectory\, \\\$fm/g" /var/www/rutorrent/plugins/filemanager/flm.class.php +perl -pi -e "s/\\\$this\-\>userdir \= addslash\(\\\$topDirectory\)\;/\\\$this\-\>userdir \= \\\$homeDirectory \? addslash\(\\\$homeDirectory\) \: addslash\(\\\$topDirectory\)\;/g" /var/www/rutorrent/plugins/filemanager/flm.class.php +perl -pi -e "s/\\\$topDirectory/\\\$homeDirectory/g" /var/www/rutorrent/plugins/filemanager/settings.js.php + +#32.4 +#unzip /etc/seedbox-from-scratch/rutorrent-oblivion.zip -d /var/www/rutorrent/plugins/ +#echo "" | tee -a /var/www/rutorrent/css/style.css > /dev/null +#echo "/* for Oblivion */" | tee -a /var/www/rutorrent/css/style.css > /dev/null +#echo ".meter-value-start-color { background-color: #E05400 }" | tee -a /var/www/rutorrent/css/style.css > /dev/null +#echo ".meter-value-end-color { background-color: #8FBC00 }" | tee -a /var/www/rutorrent/css/style.css > /dev/null +#echo "::-webkit-scrollbar {width:12px;height:12px;padding:0px;margin:0px;}" | tee -a /var/www/rutorrent/css/style.css > /dev/null +perl -pi -e "s/\$defaultTheme \= \"\"\;/\$defaultTheme \= \"Oblivion\"\;/g" /var/www/rutorrent/plugins/theme/conf.php +git clone https://github.com/InAnimaTe/rutorrent-themes.git /var/www/rutorrent/plugins/theme/themes/Extra >> $logfile 2>&1 +cp -r /var/www/rutorrent/plugins/theme/themes/Extra/OblivionBlue /var/www/rutorrent/plugins/theme/themes/ +cp -r /var/www/rutorrent/plugins/theme/themes/Extra/Agent46 /var/www/rutorrent/plugins/theme/themes/ +rm -r /var/www/rutorrent/plugins/theme/themes/Extra +#ln -s /etc/seedbox-from-scratch/seedboxInfo.php.template /var/www/seedboxInfo.php + +# 32.5 +cd /var/www/rutorrent/plugins/ +rm -r /var/www/rutorrent/plugins/fileshare +rm -r /var/www/share +svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileshare >> $logfile 2>&1 +mkdir /var/www/share +ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/share.php +ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/index.php +chown -R www-data:www-data /var/www/share +cp /etc/seedbox-from-scratch/rutorrent.plugins.fileshare.conf.php.template /var/www/rutorrent/plugins/fileshare/conf.php +perl -pi -e "s//$IPADDRESS1/g" /var/www/rutorrent/plugins/fileshare/conf.php + +mv /etc/seedbox-from-scratch/unpack.conf.php /var/www/rutorrent/plugins/unpack/conf.php + +# 33. +bash /etc/seedbox-from-scratch/updateExecutables >> $logfile 2>&1 + +#34. +echo $SBFSCURRENTVERSION1 > /etc/seedbox-from-scratch/version.info +echo $NEWFTPPORT1 > /etc/seedbox-from-scratch/ftp.info +echo $NEWSSHPORT1 > /etc/seedbox-from-scratch/ssh.info +echo $OPENVPNPORT1 > /etc/seedbox-from-scratch/openvpn.info + +# 36. +wget -P /usr/share/ca-certificates/ --no-check-certificate https://certs.godaddy.com/repository/gd_intermediate.crt https://certs.godaddy.com/repository/gd_cross_intermediate.crt +update-ca-certificates +c_rehash + +# 96. +if [ "$INSTALLOPENVPN1" = "YES" ]; then + bash /etc/seedbox-from-scratch/installOpenVPN +fi + +if [ "$INSTALLSABNZBD1" = "YES" ]; then + bash /etc/seedbox-from-scratch/installSABnzbd +fi + +if [ "$INSTALLRAPIDLEECH1" = "YES" ]; then + bash /etc/seedbox-from-scratch/installRapidleech +fi + +if [ "$INSTALLDELUGE1" = "YES" ]; then + bash /etc/seedbox-from-scratch/installDeluge +fi + +# 97. First user will not be jailed +# createSeedboxUser +bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO >> $logfile 2>&1 + +#Sickrage +sudo apt-get install python-cheetah python +sudo apt-get install git +sudo git clone https://github.com/SiCKRAGETV/SickRage.git /opt/SickRage +sudo wget http://cheapseedboxes.com/sickrage -P /etc/init.d/ +sudo chmod +x /etc/init.d/sickrage +sudo wget http://cheapseedboxes.com/csickrage -P /etc/default/ +sudo update-rc.d sickrage defaults +sudo service sickrage start + + +#Subsonic +sudo apt-get install openjdk-7-jre +wget http://subsonic.org/download/subsonic-5.2.1.deb +sudo dpkg -i subsonic-5.2.1.deb +sudo chmod -R 755 /etc/default/subsonic +sudo perl -pi -e "s/$NEWUSER1o=root/SUBSONIC_USER=$NEWUSER1/g" /etc/default/subsonic +sudo service subsonic restart + + + +#Loadavg +cd ~ +git clone https://github.com/loadavg/loadavg.git +cd loadavg +cd ~ +mv loadavg /var/www/ + + + +# 98. Cosmetic corrections & installing plowshare +#cd /var/www/rutorrent/plugins/autodl-irssi +#rm AutodlFilesDownloader.js +#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/AutodlFilesDownloader.js +#cd /var/www/rutorrent/js +#rm webui.js +#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/webui.js +cd /var/www +chown -R www-data:www-data /var/www/rutorrent +chmod -R 755 /var/www/rutorrent +cd +git clone https://github.com/mcrapet/plowshare.git plowshare +cd ~/plowshare +make install +cd +rm -r plowshare + +if [ "$OS1" = "Debian" ]; then + apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd +fi + +export EDITOR=nano +# 100 +cd /var/www/rutorrent/plugins +sleep 1 +rm -frv diskspace +wget --no-check-certificate https://bintray.com/artifact/download/hectortheone/base/pool/main/b/base/hectortheone.rar +#wget http://dl.bintray.com/novik65/generi...ace-3.6.tar.gz +#tar -xf diskspace-3.6.tar.gz +unrar x hectortheone.rar +#rm diskspace-3.6.tar.gz +rm hectortheone.rar +cd quotaspace +chmod 755 run.sh +cd .. +wget --no-check-certificate http://cheapseedboxes.com/trafic_check.rar +unrar x trafic_check.rar +rm trafic_check.rar +wget --no-check-certificate http://cheapseedboxes.com/plimits.rar +unrar x plimits.rar +rm plimits.rar +cd .. +chown -R www-data:www-data /var/www/rutorrent +set +x verbose +cd / +cd ~/ +wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb +sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb +sudo apt-get install -f +rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb + + +clear + + +echo "" +echo "<<< The Seedbox From Scratch Script >>>" +echo "Script Modified by dannyti ---> https://github.com/dannyti/" +echo "" +echo "Looks like everything is set." +echo "" +echo "Remember that your SSH port is now ======> $NEWSSHPORT1" +echo "" +echo "Your Login info can also be found at https://$IPADDRESS1/private/SBinfo.txt" +echo "Download Data Directory is located at https://$IPADDRESS1/private " +echo "" +echo "System will reboot now, but don't close this window until you take note of the port number: $NEWSSHPORT1" +echo "" +echo "" + +reboot + +##################### LAST LINE ########### From 660031be6cbede0571af7a49d60db0c65dbfea01 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Sat, 5 Sep 2015 13:30:43 +0530 Subject: [PATCH 25/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 250 ++++++++++++++++++++----------------------------- 1 file changed, 99 insertions(+), 151 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 55c9298..dfab924 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -24,12 +24,10 @@ # git clone -b master https://github.com/Notos/seedbox-from-scratch.git /etc/seedbox-from-scratch # sudo git stash; sudo git pull # -apt-get --yes install lsb-release +# SBFSCURRENTVERSION1=14.06 OS1=$(lsb_release -si) OSV1=$(lsb_release -rs) - OSV11=$(sed 's/\..*//' /etc/debian_version) - logfile="/dev/null" # # Changelog # Version 14.06 (By dannyti) @@ -264,19 +262,27 @@ PASSWORD2=b getString NO "You need to create an user for your seedbox: " NEWUSER1 getString YES "Password for user $NEWUSER1: " PASSWORD1 -getString NO "IP address of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 21976 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 21201 +getString NO "IP address or hostname of your box: " IPADDRESS1 $IPADDRESS1 +getString NO "SSH port: " NEWSSHPORT1 22 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 21 getString NO "OpenVPN port: " OPENVPNPORT1 31195 #getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES -getString NO "Install OpenVPN? " INSTALLOPENVPN1 NO +getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES +getString NO "Install Bittorent Sync ? " INSTALLBTSYNC YES getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO getString NO "Install Deluge? " INSTALLDELUGE1 NO getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 +if [ "$INSTALLBTSYNC" = "YES" ]; then +wget http://btsync.s3-website-us-east-1.amazonaws.com/btsync_x64.tar.gz +tar xf btsync_x64.tar.gz +rm btsync_x64.tar.gz +sudo mv btsync /usr/bin/btsync +fi + if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" exit 1 @@ -286,15 +292,12 @@ if [ "$OSV1" = "14.04" ]; then apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5 apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32 fi -echo "........" -echo "............." -echo "Work in Progres.......... " -echo "Please Standby................ " -apt-get --yes update >> $logfile 2>&1 -apt-get --yes install whois sudo makepasswd git nano >> $logfile 2>&1 + +apt-get --yes update +apt-get --yes install whois sudo makepasswd git nano rm -f -r /etc/seedbox-from-scratch -git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch >> $logfile 2>&1 +git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch mkdir -p cd /etc/seedbox-from-scratch/source mkdir -p cd /etc/seedbox-from-scratch/users @@ -318,21 +321,17 @@ perl -pi -e "s/X11Forwarding yes/X11Forwarding no/g" /etc/ssh/sshd_config groupadd sshdusers groupadd sftponly - +echo "" | tee -a /etc/ssh/sshd_config > /dev/null +echo "UseDNS no" | tee -a /etc/ssh/sshd_config > /dev/null +echo "AllowGroups sshdusers root" >> /etc/ssh/sshd_config mkdir -p /usr/share/terminfo/l/ cp /lib/terminfo/l/linux /usr/share/terminfo/l/ #echo '/usr/lib/openssh/sftp-server' >> /etc/shells -if [ "$OS1" = "Ubuntu" ]; then - echo "" | tee -a /etc/ssh/sshd_config > /dev/null - echo "UseDNS no" | tee -a /etc/ssh/sshd_config > /dev/null - echo "AllowGroups sshdusers root" >> /etc/ssh/sshd_config - echo "Match Group sftponly" >> /etc/ssh/sshd_config - echo "ChrootDirectory %h" >> /etc/ssh/sshd_config - echo "ForceCommand internal-sftp" >> /etc/ssh/sshd_config - echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config -fi - -service ssh reload +echo "Match Group sftponly" >> /etc/ssh/sshd_config +echo "ChrootDirectory %h" >> /etc/ssh/sshd_config +echo "ForceCommand internal-sftp" >> /etc/ssh/sshd_config +echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config +service ssh restart # 6. #remove cdrom from apt so it doesn't stop asking for it @@ -342,26 +341,23 @@ perl -pi.orig -e 's/^(deb .* universe)$/$1 multiverse/' /etc/apt/sources.list perl -pi -e "s/squeeze main/squeeze main contrib non-free/g" /etc/apt/sources.list perl -pi -e "s/squeeze-updates main/squeeze-updates main contrib non-free/g" /etc/apt/sources.list -#apt-get --yes install python-software-properties -#Adding debian pkgs for adding repo and installing ffmpeg -apt-get --yes install software-properties-common -if [ "$OSV11" = "8" ]; then - apt-add-repository --yes "deb http://www.deb-multimedia.org jessie main non-free" - apt-get update >> $logfile 2>&1 - apt-get --force-yes --yes install ffmpeg >> $logfile 2>&1 -fi - # 7. # update and upgrade packages apt-get --yes install python-software-properties software-properties-common -if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "15.04" ] || [ "$OSV1" = "14.10" ]; then +if [ "$OSV1" = "14.04" ]; then apt-add-repository --yes ppa:kirillshkrogalev/ffmpeg-next fi -apt-get --yes update >> $logfile 2>&1 -apt-get --yes upgrade >> $logfile 2>&1 +apt-get --yes update +apt-get --yes upgrade # 8. #install all needed packages -apt-get --yes install apache2 apache2-utils autoconf build-essential ca-certificates comerr-dev curl cfv quota mktorrent dtach htop irssi libapache2-mod-php5 libcloog-ppl-dev libcppunit-dev libcurl3 libcurl4-openssl-dev libncurses5-dev libterm-readline-gnu-perl libsigc++-2.0-dev libperl-dev openvpn libssl-dev libtool libxml2-dev ncurses-base ncurses-term ntp openssl patch libc-ares-dev pkg-config php5 php5-cli php5-dev php5-curl php5-geoip php5-mcrypt php5-gd php5-xmlrpc pkg-config python-scgi screen ssl-cert subversion texinfo unzip zlib1g-dev expect flex bison debhelper binutils-gold libarchive-zip-perl libnet-ssleay-perl libhtml-parser-perl libxml-libxml-perl libjson-perl libjson-xs-perl libxml-libxslt-perl libxml-libxml-perl libjson-rpc-perl libarchive-zip-perl tcpdump >> $logfile 2>&1 +apt-get --yes build-dep znc +apt-get --yes install apache2 apache2-utils autoconf build-essential vsftpd ca-certificates comerr-dev curl cfv quota mktorrent dtach htop irssi libapache2-mod-php5 libcloog-ppl-dev libcppunit-dev libcurl3 libcurl4-openssl-dev libncurses5-dev libterm-readline-gnu-perl libsigc++-2.0-dev libperl-dev openvpn libssl-dev libtool libxml2-dev ncurses-base ncurses-term ntp openssl patch libc-ares-dev pkg-config php5 php5-cli php5-dev php5-curl php5-geoip php5-mcrypt php5-gd php5-xmlrpc pkg-config python-scgi screen ssl-cert subversion texinfo unzip zlib1g-dev expect automake1.9 flex bison debhelper binutils-gold ffmpeg libarchive-zip-perl libnet-ssleay-perl libhtml-parser-perl libxml-libxml-perl libjson-perl libjson-xs-perl libxml-libxslt-perl libxml-libxml-perl libjson-rpc-perl libarchive-zip-perl znc tcpdump + +if [ "$OSV1" = "14.04"]; then + apt-get --yes install vsftpd +fi + if [ $? -gt 0 ]; then set +x verbose echo @@ -375,12 +371,9 @@ if [ $? -gt 0 ]; then set -e exit 1 fi -apt-get --yes install zip >> $logfile 2>&1 +apt-get --yes install zip -apt-get --yes install ffmpeg >> $logfile 2>&1 -apt-get --yes install automake1.9 - -apt-get --force-yes --yes install rar +apt-get --yes install rar if [ $? -gt 0 ]; then apt-get --yes install rar-free fi @@ -389,9 +382,6 @@ apt-get --yes install unrar if [ $? -gt 0 ]; then apt-get --yes install unrar-free fi -if [ "$OSV1" = "8.1" ]; then - apt-get --yes install unrar-free -fi apt-get --yes install dnsutils @@ -406,18 +396,18 @@ fi # 8.1 additional packages for Ubuntu # this is better to be apart from the others -apt-get --yes install php5-fpm >> $logfile 2>&1 -apt-get --yes install php5-xcache libxml2-dev >> $logfile 2>&1 +apt-get --yes install php5-fpm +apt-get --yes install php5-xcache -if [ "$OSV1" = "13.10" ]; then +if [ "$OSV1" = "13.10"]; then apt-get install php5-json fi #Check if its Debian and do a sysvinit by upstart replacement: -#Commented the follwoing three lines for testing -#if [ "$OS1" = "Debian" ]; then -# echo 'Yes, do as I say!' | apt-get -y --force-yes install upstart -#fi + +if [ "$OS1" = "Debian" ]; then + echo 'Yes, do as I say!' | apt-get -y --force-yes install upstart +fi # 8.3 Generate our lists of ports and RPC and create variables @@ -461,13 +451,13 @@ if [ "$INSTALLWEBMIN1" = "YES" ]; then fi if [ "$WEBMINDOWN" = "NO" ]; then - apt-get --yes update >> $logfile 2>&1 - apt-get --yes install webmin >> $logfile 2>&1 + apt-get --yes update + apt-get --yes install webmin fi fi if [ "$INSTALLFAIL2BAN1" = "YES" ]; then - apt-get --yes install fail2ban >> $logfile 2>&1 + apt-get --yes install fail2ban cp /etc/fail2ban/jail.conf /etc/fail2ban/jail.conf.original cp /etc/seedbox-from-scratch/etc.fail2ban.jail.conf.template /etc/fail2ban/jail.conf fail2ban-client reload @@ -495,11 +485,10 @@ echo "" | tee -a /etc/apache2/apache2.conf > /dev/null echo "ServerSignature Off" | tee -a /etc/apache2/apache2.conf > /dev/null echo "ServerTokens Prod" | tee -a /etc/apache2/apache2.conf > /dev/null echo "Timeout 30" | tee -a /etc/apache2/apache2.conf > /dev/null -cd /etc/apache2 rm ports.conf -wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf >> $logfile 2>&1 +wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf service apache2 restart -mkdir /etc/apache2/auth.users +mkdir /etc/apache2/auth.users echo "$IPADDRESS1" > /etc/seedbox-from-scratch/hostname.info @@ -513,27 +502,23 @@ export IPADDRESS1 echo "$NEWUSER1" > /etc/seedbox-from-scratch/mainuser.info echo "$CERTPASS1" > /etc/seedbox-from-scratch/certpass.info -bash /etc/seedbox-from-scratch/createOpenSSLCACertificate +bash /etc/seedbox-from-scratch/createOpenSSLCACertificate mkdir -p /etc/ssl/private/ openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout /etc/ssl/private/vsftpd.pem -out /etc/ssl/private/vsftpd.pem -config /etc/seedbox-from-scratch/ssl/CA/caconfig.cnf -if [ "$OSV11" = "7" ]; then +if [ "$OS1" = "Debian" ]; then + apt-get purge -y --force-yes vsftpd echo "deb http://ftp.cyconet.org/debian wheezy-updates main non-free contrib" >> /etc/apt/sources.list.d/wheezy-updates.cyconet.list apt-get update - apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd libxml2-dev libcurl4-gnutls-dev subversion >> $logfile 2>&1 -elif [ "$OSV1" = "12.04" ]; then - add-apt-repository -y ppa:thefrontiergroup/vsftpd - apt-get update - apt-get -y install vsftpd + apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd else - apt-get -y install vsftpd + apt-get --yes install libcap-dev libpam0g-dev libwrap0-dev fi - -#if [ "$OSV1" = "12.04" ]; then -# dpkg -i /etc/seedbox-from-scratch/vsftpd_2.3.2-3ubuntu5.1_`uname -m`.deb -#fi +if [ "$OSV1" = "12.04" ]; then + dpkg -i /etc/seedbox-from-scratch/vsftpd_2.3.2-3ubuntu5.1_`uname -m`.deb +fi perl -pi -e "s/anonymous_enable\=YES/\#anonymous_enable\=YES/g" /etc/vsftpd.conf perl -pi -e "s/connect_from_port_20\=YES/#connect_from_port_20\=YES/g" /etc/vsftpd.conf @@ -562,11 +547,10 @@ echo "allow_writeable_chroot=YES" | tee -a /etc/vsftpd.conf >> /dev/null #sed -i '147 d' /etc/vsftpd.conf #sed -i '149 d' /etc/vsftpd.conf -apt-get install --yes subversion >> $logfile 2>&1 -apt-get install --yes dialog >> $logfile 2>&1 + # 13. -if [ "$OSV1" = "14.04" ] || [ "$OSV1" = "14.10" ] || [ "$OSV1" = "15.04" ] || [ "$OSV11" = "8" ]; then +if [ "$OSV1" = "14.04" ]; then cp /var/www/html/index.html /var/www/index.html mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/000-default.conf.ORI rm -f /etc/apache2/sites-available/000-default.conf @@ -598,29 +582,28 @@ a2ensite default-ssl #apt-get --yes install libxmlrpc-core-c3-dev #14.1 Download xmlrpc, rtorrent & libtorrent for 0.9.4 -#cd -#svn co https://svn.code.sf.net/p/xmlrpc-c/code/stable /etc/seedbox-from-scratch/source/xmlrpc +cd +svn co https://svn.code.sf.net/p/xmlrpc-c/code/stable /etc/seedbox-from-scratch/source/xmlrpc cd /etc/seedbox-from-scratch/ #wget -c http://libtorrent.rakshasa.no/downloads/rtorrent-0.9.4.tar.gz #wget -c http://libtorrent.rakshasa.no/downloads/libtorrent-0.13.4.tar.gz -wget -c http://pkgs.fedoraproject.org/repo/pkgs/rtorrent/rtorrent-0.9.4.tar.gz/fd9490a2ac67d0fa2a567c6267845876/rtorrent-0.9.4.tar.gz >> $logfile 2>&1 -wget -c http://pkgs.fedoraproject.org/repo/pkgs/libtorrent/libtorrent-0.13.4.tar.gz/e82f380a9d4b55b379e0e73339c73895/libtorrent-0.13.4.tar.gz >> $logfile 2>&1 +wget -c http://pkgs.fedoraproject.org/repo/pkgs/rtorrent/rtorrent-0.9.4.tar.gz/fd9490a2ac67d0fa2a567c6267845876/rtorrent-0.9.4.tar.gz +wget -c http://pkgs.fedoraproject.org/repo/pkgs/libtorrent/libtorrent-0.13.4.tar.gz/e82f380a9d4b55b379e0e73339c73895/libtorrent-0.13.4.tar.gz #configure & make xmlrpc BASED ON RTORRENT VERSION if [ "$RTORRENT1" = "0.9.4" ]; then - tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.33.17.tgz -C /etc/seedbox-from-scratch/ >> $logfile 2>&1 - cd /etc/seedbox-from-scratch/xmlrpc-c-1.33.17 - ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 - make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 - make install >> $logfile 2>&1 + cd /etc/seedbox-from-scratch/source/xmlrpc + ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server + make -j$(grep -c ^processor /proc/cpuinfo) + make install else - tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.16.42.tgz -C /etc/seedbox-from-scratch/source/ >> $logfile 2>&1 + tar xvfz /etc/seedbox-from-scratch/xmlrpc-c-1.16.42.tgz -C /etc/seedbox-from-scratch/source/ cd /etc/seedbox-from-scratch/source/ - unzip ../xmlrpc-c-1.31.06.zip >> $logfile 2>&1 + unzip ../xmlrpc-c-1.31.06.zip cd xmlrpc-c-1.31.06 - ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server >> $logfile 2>&1 - make -j$(grep -c ^processor /proc/cpuinfo) >> $logfile 2>&1 - make install >> $logfile 2>&1 + ./configure --prefix=/usr --enable-libxml2-backend --disable-libwww-client --disable-wininet-client --disable-abyss-server --disable-cgi-server + make -j$(grep -c ^processor /proc/cpuinfo) + make install fi # 15. @@ -631,14 +614,14 @@ fi # 21. -bash /etc/seedbox-from-scratch/installRTorrent $RTORRENT1 >> $logfile 2>&1 +bash /etc/seedbox-from-scratch/installRTorrent $RTORRENT1 ######### Below this /var/www/rutorrent/ has been replaced with /var/www/rutorrent for Ubuntu 14.04 # 22. cd /var/www/ rm -f -r rutorrent -svn checkout https://github.com/Novik/ruTorrent/trunk rutorrent >> $logfile 2>&1 +svn checkout https://github.com/Novik/ruTorrent/trunk rutorrent #svn checkout http://rutorrent.googlecode.com/svn/trunk/plugins #rm -r -f rutorrent/plugins #mv plugins rutorrent/ @@ -652,25 +635,22 @@ echo "www-data ALL=(root) NOPASSWD: /usr/sbin/repquota" | tee -a /etc/sudoers > cp /etc/seedbox-from-scratch/favicon.ico /var/www/ # 26. Installing Mediainfo from source -apt-get install --yes mediainfo -if [ $? -gt 0 ]; then - cd /tmp - wget http://downloads.sourceforge.net/mediainfo/MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 - tar jxvf MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 >> $logfile 2>&1 - cd MediaInfo_CLI_GNU_FromSource/ - sh CLI_Compile.sh >> $logfile 2>&1 - cd MediaInfo/Project/GNU/CLI - make install >> $logfile 2>&1 -fi +cd /tmp +wget http://downloads.sourceforge.net/mediainfo/MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 +tar jxvf MediaInfo_CLI_0.7.56_GNU_FromSource.tar.bz2 +cd MediaInfo_CLI_GNU_FromSource/ +sh CLI_Compile.sh +cd MediaInfo/Project/GNU/CLI +make install cd /var/www/rutorrent/js/ -git clone https://github.com/gabceb/jquery-browser-plugin.git >> $logfile 2>&1 +git clone https://github.com/gabceb/jquery-browser-plugin.git mv jquery-browser-plugin/dist/jquery.browser.js . rm -r -f jquery-browser-plugin sed -i '31i\ ' /var/www/rutorrent/index.html cd /var/www/rutorrent/plugins -git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi >> $logfile 2>&1 +git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi #cp autodl-irssi/_conf.php autodl-irssi/conf.php #svn co https://svn.code.sf.net/p/autodl-irssi/code/trunk/rutorrent/autodl-irssi/ cd autodl-irssi @@ -682,12 +662,15 @@ echo "" | tee -a /etc/jailkit/jk_init.ini >> /dev/null bash /etc/seedbox-from-scratch/updatejkinit # 31. ZNC -#Have put this in script form +#echo "ZNC Configuration" +#echo "" +#znc --makeconf +#/home/antoniocarlos/.znc/configs/znc.conf # 32. Installing poweroff button on ruTorrent cd /var/www/rutorrent/plugins/ -wget http://rutorrent-logoff.googlecode.com/files/logoff-1.0.tar.gz >> $logfile 2>&1 -tar -zxf logoff-1.0.tar.gz >> $logfile 2>&1 +wget http://rutorrent-logoff.googlecode.com/files/logoff-1.0.tar.gz +tar -zxf logoff-1.0.tar.gz rm -f logoff-1.0.tar.gz # Installing Filemanager and MediaStream @@ -697,10 +680,10 @@ rm -f -R /var/www/rutorrent/plugins/mediastream rm -f -R /var/www/stream cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/mediastream >> $logfile 2>&1 +svn co http://svn.rutorrent.org/svn/filemanager/trunk/mediastream cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/filemanager >> $logfile 2>&1 +svn co http://svn.rutorrent.org/svn/filemanager/trunk/filemanager cp /etc/seedbox-from-scratch/rutorrent.plugins.filemanager.conf.php.template /var/www/rutorrent/plugins/filemanager/conf.php @@ -713,10 +696,10 @@ echo "" | tee /var/ # 32.2 # FILEUPLOAD cd /var/www/rutorrent/plugins/ -svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileupload >> $logfile 2>&1 +svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileupload chmod 775 /var/www/rutorrent/plugins/fileupload/scripts/upload -apt-get --yes -f install >> $logfile 2>&1 -rm /var/www/rutorrent/plugins/unpack/conf.php +apt-get --yes -f install + # 32.2 chown -R www-data:www-data /var/www/rutorrent chmod -R 755 /var/www/rutorrent @@ -734,7 +717,7 @@ perl -pi -e "s/\\\$topDirectory/\\\$homeDirectory/g" /var/www/rutorrent/plugins/ #echo ".meter-value-end-color { background-color: #8FBC00 }" | tee -a /var/www/rutorrent/css/style.css > /dev/null #echo "::-webkit-scrollbar {width:12px;height:12px;padding:0px;margin:0px;}" | tee -a /var/www/rutorrent/css/style.css > /dev/null perl -pi -e "s/\$defaultTheme \= \"\"\;/\$defaultTheme \= \"Oblivion\"\;/g" /var/www/rutorrent/plugins/theme/conf.php -git clone https://github.com/InAnimaTe/rutorrent-themes.git /var/www/rutorrent/plugins/theme/themes/Extra >> $logfile 2>&1 +git clone https://github.com/InAnimaTe/rutorrent-themes.git /var/www/rutorrent/plugins/theme/themes/Extra cp -r /var/www/rutorrent/plugins/theme/themes/Extra/OblivionBlue /var/www/rutorrent/plugins/theme/themes/ cp -r /var/www/rutorrent/plugins/theme/themes/Extra/Agent46 /var/www/rutorrent/plugins/theme/themes/ rm -r /var/www/rutorrent/plugins/theme/themes/Extra @@ -744,7 +727,7 @@ rm -r /var/www/rutorrent/plugins/theme/themes/Extra cd /var/www/rutorrent/plugins/ rm -r /var/www/rutorrent/plugins/fileshare rm -r /var/www/share -svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileshare >> $logfile 2>&1 +svn co http://svn.rutorrent.org/svn/filemanager/trunk/fileshare mkdir /var/www/share ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/share.php ln -s /var/www/rutorrent/plugins/fileshare/share.php /var/www/share/index.php @@ -752,10 +735,8 @@ chown -R www-data:www-data /var/www/share cp /etc/seedbox-from-scratch/rutorrent.plugins.fileshare.conf.php.template /var/www/rutorrent/plugins/fileshare/conf.php perl -pi -e "s//$IPADDRESS1/g" /var/www/rutorrent/plugins/fileshare/conf.php -mv /etc/seedbox-from-scratch/unpack.conf.php /var/www/rutorrent/plugins/unpack/conf.php - # 33. -bash /etc/seedbox-from-scratch/updateExecutables >> $logfile 2>&1 +bash /etc/seedbox-from-scratch/updateExecutables #34. echo $SBFSCURRENTVERSION1 > /etc/seedbox-from-scratch/version.info @@ -764,7 +745,7 @@ echo $NEWSSHPORT1 > /etc/seedbox-from-scratch/ssh.info echo $OPENVPNPORT1 > /etc/seedbox-from-scratch/openvpn.info # 36. -wget -P /usr/share/ca-certificates/ --no-check-certificate https://certs.godaddy.com/repository/gd_intermediate.crt https://certs.godaddy.com/repository/gd_cross_intermediate.crt +wget -P /usr/share/ca-certificates/ --no-check-certificate https://certs.godaddy.com/repository/gd_intermediate.crt https://certs.godaddy.com/repository/gd_cross_intermediate.crt update-ca-certificates c_rehash @@ -787,37 +768,7 @@ fi # 97. First user will not be jailed # createSeedboxUser -bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO >> $logfile 2>&1 - -#Sickrage -sudo apt-get install python-cheetah python -sudo apt-get install git -sudo git clone https://github.com/SiCKRAGETV/SickRage.git /opt/SickRage -sudo wget http://cheapseedboxes.com/sickrage -P /etc/init.d/ -sudo chmod +x /etc/init.d/sickrage -sudo wget http://cheapseedboxes.com/csickrage -P /etc/default/ -sudo update-rc.d sickrage defaults -sudo service sickrage start - - -#Subsonic -sudo apt-get install openjdk-7-jre -wget http://subsonic.org/download/subsonic-5.2.1.deb -sudo dpkg -i subsonic-5.2.1.deb -sudo chmod -R 755 /etc/default/subsonic -sudo perl -pi -e "s/$NEWUSER1o=root/SUBSONIC_USER=$NEWUSER1/g" /etc/default/subsonic -sudo service subsonic restart - - - -#Loadavg -cd ~ -git clone https://github.com/loadavg/loadavg.git -cd loadavg -cd ~ -mv loadavg /var/www/ - - +bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YES NO # 98. Cosmetic corrections & installing plowshare #cd /var/www/rutorrent/plugins/autodl-irssi @@ -857,9 +808,6 @@ cd .. wget --no-check-certificate http://cheapseedboxes.com/trafic_check.rar unrar x trafic_check.rar rm trafic_check.rar -wget --no-check-certificate http://cheapseedboxes.com/plimits.rar -unrar x plimits.rar -rm plimits.rar cd .. chown -R www-data:www-data /var/www/rutorrent set +x verbose From 73d4aa3e6550de53a8a46a8f62166c9e1ff0fa32 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 23 Sep 2015 23:33:18 +0530 Subject: [PATCH 26/32] Update sbfrmsc-dti.sh From 49e27b977f5844e63e2c6d8829d38c22de0ac9cf Mon Sep 17 00:00:00 2001 From: fravia1 Date: Mon, 26 Oct 2015 04:48:12 +0530 Subject: [PATCH 27/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index dfab924..3b08bec 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Updated for $.broswer-msie error; will populate tracker list properly ; create check/start scripts; +# Updated for $.broswer-msie error; will populate tracker list properly ; create check/start scripts; # create crontab entries. Rest is all perfect from Notos. Thanks. # # The Seedbox From Scratch Script @@ -11,9 +11,9 @@ # # Copyright (c) 2013 Notos (https://github.com/Notos/) & dannyti (https://github.com/dannyti/) # -# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: +# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: # -# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. +# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # @@ -33,17 +33,17 @@ # Version 14.06 (By dannyti) # Jan 16 2015 # - RTorrent 0.9.4 supported -# - Openvpn Fixed and Working +# - Openvpn Fixed and Working # - Autodl tracker list correctly populated # - Diskspace fixed for multiuser environment # - Added http Data Download directory for users ; Can be accessed at http://Server-IP/private/Downloads ; Only http:// -# - Sitewide https only -# - User Login info can be accessed individually at http://Server-IP/private/SBinfo.txt +# - Sitewide https only +# - User Login info can be accessed individually at http://Server-IP/private/SBinfo.txt # - Mediainfo fixed ; installtion from source -# - Jquery Error corrected +# - Jquery Error corrected # - Crontab entries made for checking rtorrrent is running and starting it if not running # - Plowshare Fixed -# - Deprecated seedboxInfo.php +# - Deprecated seedboxInfo.php # # Version 2.1.9 (not stable yet) # Dec 26 2012 17:37 GMT-3 @@ -294,10 +294,10 @@ if [ "$OSV1" = "14.04" ]; then fi apt-get --yes update -apt-get --yes install whois sudo makepasswd git nano +apt-get --yes install whois sudo makepasswd git nano rm -f -r /etc/seedbox-from-scratch -git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch +git clone -b v$SBFSCURRENTVERSION1 https://github.com/fravia1/seedbox-from-scratch.git /etc/seedbox-from-scratch mkdir -p cd /etc/seedbox-from-scratch/source mkdir -p cd /etc/seedbox-from-scratch/users @@ -471,7 +471,7 @@ a2enmod rewrite #a2enmod scgi ############### if we cant make python-scgi works #cd /etc/apache2 #rm apache2.conf -#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/apache2.conf +#wget --no-check-certificate https://raw.githubusercontent.com/fravia1/sboxsetup/master/apache2.conf cat /etc/seedbox-from-scratch/add2apache2.conf >> /etc/apache2/apache2.conf # 10. @@ -486,7 +486,7 @@ echo "ServerSignature Off" | tee -a /etc/apache2/apache2.conf > /dev/null echo "ServerTokens Prod" | tee -a /etc/apache2/apache2.conf > /dev/null echo "Timeout 30" | tee -a /etc/apache2/apache2.conf > /dev/null rm ports.conf -wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf +wget --no-check-certificate https://raw.githubusercontent.com/fravia1/sboxsetup/master/ports.conf service apache2 restart mkdir /etc/apache2/auth.users @@ -551,7 +551,7 @@ echo "allow_writeable_chroot=YES" | tee -a /etc/vsftpd.conf >> /dev/null # 13. if [ "$OSV1" = "14.04" ]; then - cp /var/www/html/index.html /var/www/index.html + cp /var/www/html/index.html /var/www/index.html mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/000-default.conf.ORI rm -f /etc/apache2/sites-available/000-default.conf cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/000-default.conf @@ -656,7 +656,7 @@ git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi cd autodl-irssi -# 30. +# 30. cp /etc/jailkit/jk_init.ini /etc/jailkit/jk_init.ini.original echo "" | tee -a /etc/jailkit/jk_init.ini >> /dev/null bash /etc/seedbox-from-scratch/updatejkinit @@ -780,7 +780,7 @@ bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YE cd /var/www chown -R www-data:www-data /var/www/rutorrent chmod -R 755 /var/www/rutorrent -cd +cd git clone https://github.com/mcrapet/plowshare.git plowshare cd ~/plowshare make install @@ -790,7 +790,7 @@ rm -r plowshare if [ "$OS1" = "Debian" ]; then apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd fi - + export EDITOR=nano # 100 cd /var/www/rutorrent/plugins From 23e04a6dc8bed148a1e2c531c0929982f6344f09 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Mon, 26 Oct 2015 05:07:47 +0530 Subject: [PATCH 28/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 3b08bec..220a6a1 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -297,7 +297,7 @@ apt-get --yes update apt-get --yes install whois sudo makepasswd git nano rm -f -r /etc/seedbox-from-scratch -git clone -b v$SBFSCURRENTVERSION1 https://github.com/fravia1/seedbox-from-scratch.git /etc/seedbox-from-scratch +git clone -b https://github.com/fravia1/seedbox-from-scratch.git /etc/seedbox-from-scratch mkdir -p cd /etc/seedbox-from-scratch/source mkdir -p cd /etc/seedbox-from-scratch/users From eb47c38ee0d041d61cfb9f874f43898332502a1f Mon Sep 17 00:00:00 2001 From: fravia1 Date: Mon, 26 Oct 2015 08:35:06 +0530 Subject: [PATCH 29/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 57 ++++++++++++++++---------------------------------- 1 file changed, 18 insertions(+), 39 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 220a6a1..6f0d3a2 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Updated for $.broswer-msie error; will populate tracker list properly ; create check/start scripts; +# Updated for $.broswer-msie error; will populate tracker list properly ; create check/start scripts; # create crontab entries. Rest is all perfect from Notos. Thanks. # # The Seedbox From Scratch Script @@ -11,9 +11,9 @@ # # Copyright (c) 2013 Notos (https://github.com/Notos/) & dannyti (https://github.com/dannyti/) # -# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: +# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: # -# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. +# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # @@ -33,17 +33,17 @@ # Version 14.06 (By dannyti) # Jan 16 2015 # - RTorrent 0.9.4 supported -# - Openvpn Fixed and Working +# - Openvpn Fixed and Working # - Autodl tracker list correctly populated # - Diskspace fixed for multiuser environment # - Added http Data Download directory for users ; Can be accessed at http://Server-IP/private/Downloads ; Only http:// -# - Sitewide https only -# - User Login info can be accessed individually at http://Server-IP/private/SBinfo.txt +# - Sitewide https only +# - User Login info can be accessed individually at http://Server-IP/private/SBinfo.txt # - Mediainfo fixed ; installtion from source -# - Jquery Error corrected +# - Jquery Error corrected # - Crontab entries made for checking rtorrrent is running and starting it if not running # - Plowshare Fixed -# - Deprecated seedboxInfo.php +# - Deprecated seedboxInfo.php # # Version 2.1.9 (not stable yet) # Dec 26 2012 17:37 GMT-3 @@ -263,26 +263,18 @@ PASSWORD2=b getString NO "You need to create an user for your seedbox: " NEWUSER1 getString YES "Password for user $NEWUSER1: " PASSWORD1 getString NO "IP address or hostname of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 22 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 21 +getString NO "SSH port: " NEWSSHPORT1 21 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 22 getString NO "OpenVPN port: " OPENVPNPORT1 31195 #getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES -getString NO "Install Bittorent Sync ? " INSTALLBTSYNC YES getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO getString NO "Install Deluge? " INSTALLDELUGE1 NO getString NO "Wich RTorrent version would you like to install, '0.9.2' or '0.9.3' or '0.9.4'? " RTORRENT1 0.9.4 -if [ "$INSTALLBTSYNC" = "YES" ]; then -wget http://btsync.s3-website-us-east-1.amazonaws.com/btsync_x64.tar.gz -tar xf btsync_x64.tar.gz -rm btsync_x64.tar.gz -sudo mv btsync /usr/bin/btsync -fi - if [ "$RTORRENT1" != "0.9.3" ] && [ "$RTORRENT1" != "0.9.2" ] && [ "$RTORRENT1" != "0.9.4" ]; then echo "$RTORRENT1 typed is not 0.9.4 or 0.9.3 or 0.9.2!" exit 1 @@ -294,10 +286,10 @@ if [ "$OSV1" = "14.04" ]; then fi apt-get --yes update -apt-get --yes install whois sudo makepasswd git nano +apt-get --yes install whois sudo makepasswd git nano rm -f -r /etc/seedbox-from-scratch -git clone -b https://github.com/fravia1/seedbox-from-scratch.git /etc/seedbox-from-scratch +git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch mkdir -p cd /etc/seedbox-from-scratch/source mkdir -p cd /etc/seedbox-from-scratch/users @@ -471,7 +463,7 @@ a2enmod rewrite #a2enmod scgi ############### if we cant make python-scgi works #cd /etc/apache2 #rm apache2.conf -#wget --no-check-certificate https://raw.githubusercontent.com/fravia1/sboxsetup/master/apache2.conf +#wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/apache2.conf cat /etc/seedbox-from-scratch/add2apache2.conf >> /etc/apache2/apache2.conf # 10. @@ -486,7 +478,7 @@ echo "ServerSignature Off" | tee -a /etc/apache2/apache2.conf > /dev/null echo "ServerTokens Prod" | tee -a /etc/apache2/apache2.conf > /dev/null echo "Timeout 30" | tee -a /etc/apache2/apache2.conf > /dev/null rm ports.conf -wget --no-check-certificate https://raw.githubusercontent.com/fravia1/sboxsetup/master/ports.conf +wget --no-check-certificate https://raw.githubusercontent.com/dannyti/sboxsetup/master/ports.conf service apache2 restart mkdir /etc/apache2/auth.users @@ -551,7 +543,7 @@ echo "allow_writeable_chroot=YES" | tee -a /etc/vsftpd.conf >> /dev/null # 13. if [ "$OSV1" = "14.04" ]; then - cp /var/www/html/index.html /var/www/index.html + cp /var/www/html/index.html /var/www/index.html mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/000-default.conf.ORI rm -f /etc/apache2/sites-available/000-default.conf cp /etc/seedbox-from-scratch/etc.apache2.default.template /etc/apache2/sites-available/000-default.conf @@ -656,7 +648,7 @@ git clone https://github.com/autodl-community/autodl-rutorrent.git autodl-irssi cd autodl-irssi -# 30. +# 30. cp /etc/jailkit/jk_init.ini /etc/jailkit/jk_init.ini.original echo "" | tee -a /etc/jailkit/jk_init.ini >> /dev/null bash /etc/seedbox-from-scratch/updatejkinit @@ -780,7 +772,7 @@ bash /etc/seedbox-from-scratch/createSeedboxUser $NEWUSER1 $PASSWORD1 YES YES YE cd /var/www chown -R www-data:www-data /var/www/rutorrent chmod -R 755 /var/www/rutorrent -cd +cd git clone https://github.com/mcrapet/plowshare.git plowshare cd ~/plowshare make install @@ -790,7 +782,7 @@ rm -r plowshare if [ "$OS1" = "Debian" ]; then apt-get install -y --force-yes -t wheezy-updates debian-cyconet-archive-keyring vsftpd fi - + export EDITOR=nano # 100 cd /var/www/rutorrent/plugins @@ -805,23 +797,10 @@ rm hectortheone.rar cd quotaspace chmod 755 run.sh cd .. -wget --no-check-certificate http://cheapseedboxes.com/trafic_check.rar -unrar x trafic_check.rar -rm trafic_check.rar -cd .. chown -R www-data:www-data /var/www/rutorrent set +x verbose -cd / -cd ~/ -wget -c http://downloads.plexapp.com/plex-media-server/0.9.9.12.504-3e7f93c/plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb -sudo dpkg -i plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb -sudo apt-get install -f -rm plexmediaserver_0.9.9.12.504-3e7f93c_amd64.deb - - clear - echo "" echo "<<< The Seedbox From Scratch Script >>>" echo "Script Modified by dannyti ---> https://github.com/dannyti/" From 46e2191e21ad8882552f3c1049c8013a17f04663 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Mon, 26 Oct 2015 08:38:10 +0530 Subject: [PATCH 30/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 6f0d3a2..2c6f592 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -263,8 +263,8 @@ PASSWORD2=b getString NO "You need to create an user for your seedbox: " NEWUSER1 getString YES "Password for user $NEWUSER1: " PASSWORD1 getString NO "IP address or hostname of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 21 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 22 +getString NO "SSH port: " NEWSSHPORT1 22 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 21 getString NO "OpenVPN port: " OPENVPNPORT1 31195 #getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES getString NO "Install Webmin? " INSTALLWEBMIN1 YES From 3b9dcd72985324f1e8b29567c28cda1a889b7540 Mon Sep 17 00:00:00 2001 From: fravia1 Date: Wed, 9 Dec 2015 01:45:09 +0530 Subject: [PATCH 31/32] Update sbfrmsc-dti.sh --- sbfrmsc-dti.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index 2c6f592..dd488db 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -263,13 +263,13 @@ PASSWORD2=b getString NO "You need to create an user for your seedbox: " NEWUSER1 getString YES "Password for user $NEWUSER1: " PASSWORD1 getString NO "IP address or hostname of your box: " IPADDRESS1 $IPADDRESS1 -getString NO "SSH port: " NEWSSHPORT1 22 -getString NO "vsftp port (usually 21): " NEWFTPPORT1 21 +getString NO "SSH port: " NEWSSHPORT1 21976 +getString NO "vsftp port (usually 21): " NEWFTPPORT1 21201 getString NO "OpenVPN port: " OPENVPNPORT1 31195 #getString NO "Do you want to have some of your users in a chroot jail? " CHROOTJAIL1 YES getString NO "Install Webmin? " INSTALLWEBMIN1 YES getString NO "Install Fail2ban? " INSTALLFAIL2BAN1 YES -getString NO "Install OpenVPN? " INSTALLOPENVPN1 YES +getString NO "Install OpenVPN? " INSTALLOPENVPN1 NO getString NO "Install SABnzbd? " INSTALLSABNZBD1 NO getString NO "Install Rapidleech? " INSTALLRAPIDLEECH1 NO getString NO "Install Deluge? " INSTALLDELUGE1 NO From f3035b6c8cec940642a0705adcb333f0157cd9fb Mon Sep 17 00:00:00 2001 From: miloshpetrov Date: Tue, 8 Dec 2015 22:20:34 +0100 Subject: [PATCH 32/32] using older revision of sfc --- sbfrmsc-dti.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/sbfrmsc-dti.sh b/sbfrmsc-dti.sh index dd488db..7d4db48 100644 --- a/sbfrmsc-dti.sh +++ b/sbfrmsc-dti.sh @@ -290,6 +290,7 @@ apt-get --yes install whois sudo makepasswd git nano rm -f -r /etc/seedbox-from-scratch git clone -b v$SBFSCURRENTVERSION1 https://github.com/dannyti/seedbox-from-scratch.git /etc/seedbox-from-scratch +bash -c 'cd /etc/seedbox-from-scratch && git checkout 72c60d29730c31bec795ea63f7e5b88556ad2efd' mkdir -p cd /etc/seedbox-from-scratch/source mkdir -p cd /etc/seedbox-from-scratch/users