Installation de ISPConfig en mode manuel

Installation de ISPConfig en mode manuel.
Raspberry Pi : Version 1
1/ Configuration de base d’un Raspberry Pi :
Voir mes autres didacticiels.
2/ Connexion en ‘administrateur‘/’root‘ :

pi@raspberrypi:~ $ sudo su
root@raspberrypi:/home/pi#

3/ Variable d’environnement de base :

CFG_HOSTNAME_FQDN=`hostname -f`

3/ Activation des sources dans ‘/etc/apt/source.list‘.
4/ Mise-à-jour du système :

# apt-get update && sudo apt-get upgrade

5/ Installation des paquets de base :

# apt-get install mc screen links htop

6/ Variables d’environnement pour SSL :

SSL_COUNTRY=FR
SSL_STATE=MeM
SSL_LOCALITY=Mexy
SSL_ORGANIZATION=SteamCyberPunk
SSL_ORGUNIT=ITService

7/ Installation des paquets de base pour ‘ISPConfig‘ :

# apt-get install ssh openssh-server vim-nox php5-cli ntp ntpdate debconf-utils binutils sudo git lsb-release haveged e2fsprogs

8/ Installation de ‘MySQL‘ :

# apt-get install mysql-client mysql-server
# sed -i 's/bind-address		= 127.0.0.1/#bind-address		= 127.0.0.1/' /etc/mysql/my.cnf
# service mysql restart

9/ Installation du serveur web ‘Apache2‘ :
– Installation de Apache2 :

# apt-get install apache2 apache2.2-common apache2-doc apache2-mpm-prefork apache2-utils libapache2-mod-php5 libapache2-mod-fcgid apache2-suexec libapache2-mod-passenger libapache2-mod-python libexpat1 ssl-cert libruby

– Installation des modules Apache2 :

# apt-get install php5 php5-common php5 php5-common php5-dev php5-gd php5-mysqlnd php5-imap php5-cli php5-cgi php-pear php-auth php5-fpm php5-mcrypt php5-imagick php5-curl php5-intl php5-memcached php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xmlrpc php5-xsl

– Installation d’autres composants :

# apt-get install mcrypt imagemagick memcached curl tidy snmp
# apt-get install php5-xcache

– Installation de ‘PhpMyAdmin‘ :

# apt-get install phpmyadmin

– Activation des modules :

a2enmod suexec
a2enmod rewrite
a2enmod ssl
a2enmod actions
a2enmod include
a2enmod dav_fs
a2enmod dav
a2enmod auth_digest
a2enmod alias
a2enmod fcgid
service apache2 restart

10/ Installation de ‘pureftpd‘ :
– Installation des paquets :

# apt-get install pure-ftpd-common pure-ftpd-mysql

– Fichier de configuration :

sed -i 's/ftp/\#ftp/' /etc/inetd.conf
echo 1 > /etc/pure-ftpd/conf/TLS
mkdir -p /etc/ssl/private/
openssl req -x509 -nodes -days 3650 -newkey rsa:2048 -keyout /etc/ssl/private/pure-ftpd.pem -out /etc/ssl/private/pure-ftpd.pem -subj "/C=$SSL_COUNTRY/ST=$SSL_STATE/L=$SSL_LOCALITY/O=$SSL_ORGANIZATION/OU=$SSL_ORGUNIT/CN=$CFG_HOSTNAME_FQDN"
chmod 600 /etc/ssl/private/pure-ftpd.pem

– Redémarrage du service :

service openbsd-inetd restart
service pure-ftpd-mysql restart

11/ Installation de ‘Php‘ :

# apt-get install php5-cli php5-mysql php5-mcrypt mcrypt

11/ Installation de ‘bind‘ :

# apt-get install bind9 dnsutils

12/ Installation de ‘awstats‘ :

# apt-get install vlogger webalizer awstats geoip-database libclass-dbi-mysql-perl
# sed -i 's/^/#/' /etc/cron.d/awstats

13/ Installation de ‘ISPConfig‘ :
– Variable d’environnement :

CFG_MYSQL_ROOT_PWD=mot2passe

– Installation :

# wget http://www.ispconfig.org/downloads/ISPConfig-3-stable.tar.gz
# tar xfz ISPConfig-3-stable.tar.gz
# cd ispconfig3_install/install/

– Fichier de configuration :

echo "[install]" > autoinstall.ini
echo "language=en" >> autoinstall.ini
echo "install_mode=$CFG_ISPC" >> autoinstall.ini
echo "hostname=$CFG_HOSTNAME_FQDN" >> autoinstall.ini
echo "mysql_hostname=localhost" >> autoinstall.ini
echo "mysql_root_user=root" >> autoinstall.ini
echo "mysql_root_password=$CFG_MYSQL_ROOT_PWD" >> autoinstall.ini
echo "mysql_database=dbispconfig" >> autoinstall.ini
echo "mysql_port=3306" >> autoinstall.ini
echo "mysql_charset=utf8" >> autoinstall.ini
echo "http_server=apache" >> autoinstall.ini
echo "http_server=" >> autoinstall.ini
echo "ispconfig_port=8080" >> autoinstall.ini
echo "ispconfig_use_ssl=n" >> autoinstall.ini
echo
echo "[ssl_cert]" >> autoinstall.ini
echo "ssl_cert_country=$SSL_COUNTRY" >> autoinstall.ini
echo "ssl_cert_state=$SSL_STATE" >> autoinstall.ini
echo "ssl_cert_locality=$SSL_LOCALITY" >> autoinstall.ini
echo "ssl_cert_organisation=$SSL_ORGANIZATION" >> autoinstall.ini
echo "ssl_cert_organisation_unit=$SSL_ORGUNIT" >> autoinstall.ini
echo "ssl_cert_common_name=$CFG_HOSTNAME_FQDN" >> autoinstall.ini
echo "[expert]" >> autoinstall.ini
echo "mysql_ispconfig_user=ispconfig" >> autoinstall.ini
echo "mysql_ispconfig_password=afStEratXBsgatRtsa42CadwhQ" >> autoinstall.ini
echo "join_multiserver_setup=$MULTISERVER" >> autoinstall.ini
echo "mysql_master_hostname=$CFG_MASTER_FQDN" >> autoinstall.ini
echo "mysql_master_root_user=root" >> autoinstall.ini
echo "mysql_master_root_password=$CFG_MASTER_MYSQL_ROOT_PWD" >> autoinstall.ini
echo "mysql_master_database=dbispconfig" >> autoinstall.ini
echo "configure_mail=$CFG_SETUP_MAIL" >> autoinstall.ini
 echo "configure_jailkit=n" >> autoinstall.ini
echo "configure_ftp=$CFG_SETUP_WEB" >> autoinstall.ini
echo "configure_dns=$CFG_SETUP_NS" >> autoinstall.ini
echo "configure_apache=$CFG_APACHE" >> autoinstall.ini
echo "configure_nginx=$CFG_NGINX" >> autoinstall.ini
echo "configure_firewall=y" >> autoinstall.ini
echo "install_ispconfig_web_interface=$CFG_SETUP_MASTER" >> autoinstall.ini
echo
echo "[update]" >> autoinstall.ini
echo "do_backup=yes" >> autoinstall.ini
echo "mysql_root_password=$CFG_MYSQL_ROOT_PWD" >> autoinstall.ini
echo "mysql_master_hostname=$CFG_MASTER_FQDN" >> autoinstall.ini
echo "mysql_master_root_user=root" >> autoinstall.ini
echo "mysql_master_root_password=$CFG_MASTER_MYSQL_ROOT_PWD" >> autoinstall.ini
echo "mysql_master_database=dbispconfig" >> autoinstall.ini
echo "reconfigure_permissions_in_master_database=no" >> autoinstall.ini
echo "reconfigure_services=yes" >> autoinstall.ini
echo "ispconfig_port=8080" >> autoinstall.ini
echo "create_new_ispconfig_ssl_cert=no" >> autoinstall.ini
echo "reconfigure_crontab=yes" >> autoinstall.ini

– Installation :

# php -q install.php --autoinstall=autoinstall.ini

– Redémarrage du service :

# /etc/init.d/apache2 restart

14/ Configuration de ‘ISPConfig‘ :
– Page d’accueil :
http://192.168.1.23:8080/index.php
– Accès :
Utilisateur : admin
Mot de passe : admin
15/ Sous ISPConfig, ajouter un site web :
Domain : framboisepi.localhost
Avec le support Php : Mod-PHP
16/ Configuration d’un poste distant :
Ouvrir :

/etc/hosts

Ajouter :

192.168.1.23    framboisepi.localhost

17/ Test :
Site web de test : framboisepi.localhost
La page d’index par défaut s’affiche.
18/ Liens :
http://www.ispconfig.org/
https://www.howtoforge.com/tutorial/ispconfig-install-script-debian/

Comments are closed, but trackbacks and pingbacks are open.