Current time: 12-22-2024, 09:38 PM Hello There, Guest! (LoginRegister)


Post Reply 
ISPCP Debian Lenny Autoinstaller
Author Message
alecksievici Offline
Junior Member
*
Beta Team

Posts: 112
Joined: May 2008
Reputation: 0
Post: #1
ISPCP Debian Lenny Autoinstaller
I've created a bash script that simplifies the install process of ISPCP in Debian Lenny. The only step you have to take before using the script si to set a valid FQDN.

Code:
#!/bin/bash
#
# +----------------------------------------------------------------------------+
# | ISPCP 1.0.6 - Debian Lenny Install Script v0.1a                            |
# | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
# | Usage: chmod +x ispcp-debian.sh ; ./ispcp-debian.sh                        |
# +----------------------------------------------------------------------------+
#

# Clear the screen
clear

# Set colors & stuff
red='\E[31m'
white='\E[37m'
bold='\033[1m'
resetcolors=`tput sgr0`

# Install function for automatization
function install_ispcp {

# Modify sources.list according to ISPCP requirements
cp -f /etc/apt/sources.list /etc/apt/sources.list.old

echo "deb http://ftp.debian.org/debian/ lenny main contrib non-free
deb http://security.debian.org/ lenny/updates main
deb http://volatile.debian.org/debian-volatile lenny/volatile main" > /etc/apt/sources.list

# Update, install aptitude and some required packages for install
apt-get update
apt-get -y install aptitude
aptitude update
aptitude -y install tar bzip2 wget lsb-release perl

# Make ispcp src dir & enter it
mkdir -p /usr/local/src/ispcp
cd /usr/local/src/ispcp

# Download ISPCP 1.0.6
wget="$(which wget)"
tar="$(which tar)"

$wget --output-document=ispcp-omega-1.0.6.tar.bz2 http://sourceforge.net/projects/ispcp/files/ispCP%20Omega/ispCP%20Omega%201.0.6/ispcp-omega-1.0.6.tar.bz2/download
$tar -xf ispcp-omega-1.0.6.tar.bz2

cd ispcp-omega-1.0.6/

# Installing required packages for ISPCP
aptitude -y install $(cat ./docs/Debian/debian-packages-`lsb_release -cs`)

# Make install ISPCP
make install

# Copy files
cp -R /tmp/ispcp/* /

# Setting MySQL
mysql_secure_installation

# Enter ISPCP setup
perl="$(which perl)"
cd /var/www/ispcp/engine/setup
$perl ./ispcp-setup

# Removing unedeed files
rm -fR /tmp/ispcp
rm -fR /usr/local/src/ispcp

# You're done!
}

echo -e $bold$red"You should use this script only on a freshly installed Debian Lenny!"$resetcolors
echo -e $bold"Before installing please set up a correct FQDN: "$resetcolors"http://isp-control.net/documentation/howto:hostname"
echo -e $bold"Download the latest version: "$resetcolors"http://ispcp.greenbit.ro/ispcp-debian.sh"
echo ""
echo -e "When you get to the courier screen select "$bold"no"$resetcolors" to web directories."
echo -e "When you get to the postfix screen select "$bold"internet site"$resetcolors". If your debian setup is correct your domain should already be displayed on the screen. If not, enter the domain without the 'www.' portion (i.e. yourdomain.com)."
echo -e "Select "$bold"no"$resetcolors" when you are asked if you would like to create directories for web-based administration"
echo -e "When you get to the proftpd screen, select "$bold"standalone"$resetcolors"."
echo ""

read -p "Continue (y/n)? " choice
   case "$choice" in
      y|Y ) install_ispcp;;
      n|N ) exit 1;;
      * ) exit 1;;
esac

If you see any bugs let me know. This script was tested and it works.

Cheers,
Alex
09-27-2010 10:48 PM
Visit this user's website Find all posts by this user Quote this message in a reply
RatS Offline
Project Leader
******

Posts: 1,854
Joined: Oct 2006
Reputation: 17
Post: #2
RE: ISPCP Debian Lenny Autoinstaller
Thank you Alex.

I hope, that some people try the script and give feedback. We could add it as contrib in Release 1.0.7 if it is tested.

PS: I moved the post to Enhancements.
09-28-2010 01:11 AM
Visit this user's website Find all posts by this user Quote this message in a reply
alecksievici Offline
Junior Member
*
Beta Team

Posts: 112
Joined: May 2008
Reputation: 0
Post: #3
RE: ISPCP Debian Lenny Autoinstaller
I've updated the script to work with ISPCP 1.0.7
Code:
wget http://ispcp.greenbit.ro/ispcp-debian.sh
chmod +x ispcp-debian.sh
./ispcp-debian.sh

Enjoy and good luck.
11-26-2010 06:00 PM
Visit this user's website Find all posts by this user Quote this message in a reply
RatS Offline
Project Leader
******

Posts: 1,854
Joined: Oct 2006
Reputation: 17
Post: #4
RE: ISPCP Debian Lenny Autoinstaller
great, do you want to help us improving the installation and upgrade process to reduce manual steps?
11-26-2010 06:44 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Jillian Offline
Junior Member
*

Posts: 51
Joined: Mar 2009
Reputation: 1
Post: #5
RE: ISPCP Debian Lenny Autoinstaller
Few suggestion to script.
Get closest mirrors to sources.list. Check this.
One other this is if ispCP team can make package ispcp-omega-latest.tar.bz2, you dont have to make modifications to script, when new release is out.
11-26-2010 11:25 PM
Visit this user's website Find all posts by this user Quote this message in a reply
giotjuh Offline


Posts: 4
Joined: Mar 2011
Reputation: 0
Post: #6
RE: ISPCP Debian Lenny Autoinstaller
Awesome mate! Maybe one for the 1.1.0 beta release to test it out Big Grin
(This post was last modified: 12-31-2011 01:53 AM by giotjuh.)
12-31-2011 01:53 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)