Cara Install ISPConfig 3 di Ubuntu 16.04 – Memiliki web hosting sendiri pastinya sungguh menyenangkan, karena kita tidak perlu lagi sewa hosting yang mahal untuk menaruh data web kita. Cukup memiliki satu IP static dari penyedia layanan seperti telkom atau yang lainnya. Kali ini saya akan berbagi bagaimana membuat webhosting sendiri menggunakan ubuntu server dan ispconfig. Berikut ini Cara Install ISPConfig di Ubuntu 16.04
ISPConfig adalah aplikasi control panel web hosting dengan lisensi open source dan bisa didapatkan dengan gratis. ISPConfig mendukung single dan multi server, mendukung berbagai distro Linux (Debian, Ubuntu, CentOS, Fedora, openSUSE), dengan 4 level access (admin, reseller, client, email login), dan mendukung berbagai services (HTTP, SMTP, POP3/IMAP, FTP, DNS, Database). ISPConfig menyediakan live demo untuk administrator, client, dan reseller. Untuk mendanai pengembangan ISPConfig, buku manual penggunaan ISPConfig dijual dengan harga 5euro.
Tahapan install ISPConfig termasuk yang paling panjang di antara control panel web hosting yang pernah saya coba berdasarkan tutorial di halaman ini. Kemudian ada seorang developer dari perusahaan provider server Servisys yang bernama Matteo Temporini membuat script ispconfig_setup untuk memudahkan install ISPConfig.
ispconfig_setup telah diuji di berbagai distro Linux, yaitu Debian 7/8/9, Ubuntu 14.04/15.10/16.04/18/04, CentOS 7. Namun tidak semua distro memiliki fitur yang sama, daftar fiturnya dapat dilihat di halaman GitHub.
Sebelum kita install ispconfig, kita update dan upgrade dulu ubuntu kita
[box type=”shadow” align=”” class=”” width=””]apt-get update && apt-get upgrade[/box]
Stop and remove Apparmor, Sendmail
[box type=”shadow” align=”” class=”” width=””]service apparmor stop
update-rc.d -f apparmor remove
apt-get remove -y apparmor apparmor-utils
service sendmail stop; update-rc.d -f sendmail remove[/box]
Install VIM-NOX, SSH Server, Sudo, NTP
[box type=”shadow” align=”” class=”” width=””]apt-get install -y software-properties-common
apt-transport-https apt-get install -y ssh openssh-server sudo ntp ntpdate
service sendmail stop; update-rc.d -f sendmail remove[/box]
Install Softwares Mail Server
[box type=”shadow” align=”” class=”” width=””]apt-get install -y postfix postfix-mysql mariadb-client mariadb-server
apt-get install -y openssl getmail4 binutils
apt-get install -y dovecot-pop3d dovecot-mysql dovecot-sieve dovecot-lmtpd dovecot-imapd
apt-get install -y amavisd-new spamassassin zoo libnet-ldap-perl
apt-get install -y clamav clamav-base clamav-daemon clamav-freshclam
apt-get install -y unzip bzip2 arj nomarch lzop cabextract
apt-listchanges apt-get install -y libauthen-sasl-perl daemon libio-string-perl libjson-perl
apt-get install -y libio-socket-ssl-perl libnet-ident-perl zip libnet-dns-perl postgrey[/box]
## Stop Spamassassin[box type=”shadow” align=”” class=”” width=””]service spamassassin stop
update-rc.d -f spamassassin remove[/box]
freshclam -v
[box type=”shadow” align=”” class=”” width=””]sed -i ‘s|AllowSupplementaryGroups false|AllowSupplementaryGroups true|’ /etc/clamav/clamd.conf
freshclam
service clamav-daemon start
sed -i ‘s|bind-address|#bind-address|’ /etc/mysql/mariadb.conf.d/50-server.cnf
[/box]
Backup Postfix
[box type=”shadow” align=”” class=”” width=””]mkdir -p /etc/postfix/backup
cp -aR /etc/postfix/* /etc/postfix/backup/[/box]
Backup Dovecot
[box type=”shadow” align=”” class=”” width=””]mkdir -p /etc/dovecot/backup
cp -aR /etc/dovecot/* /etc/dovecot/backup/[/box]
Config Postfix /etc/postfix/master.cf
[box type=”shadow” align=”” class=”” width=””]sed -i ‘s|#submission|submission|’ /etc/postfix/master.cf
sed -i ‘s|# -o syslog_name=postfix/submission| -o syslog_name=postfix/submission|’ /etc/postfix/master.cf
sed -i ‘s|# -o smtpd_tls_security_level=encrypt| -o smtpd_tls_security_level=may|’ /etc/postfix/master.cf
sed -i ‘s|# -o smtpd_sasl_auth_enable=yes| -o smtpd_sasl_auth_enable=yes|’ /etc/postfix/master.cf
sed -i ‘s|# -o smtpd_reject_unlisted_recipient=no| -o smtpd_client_restrictions=permit_sasl_authenticated,reject|’ /etc/postfix/master.cf sed -i ‘s|#smtps|smtps|’ /etc/postfix/master.cf
sed -i ‘s|# -o syslog_name=postfix/smtps| -o syslog_name=postfix/smtps|’ /etc/postfix/master.cf
sed -i ‘s|# -o smtpd_tls_wrappermode=yes| -o smtpd_tls_wrappermode=yes|’ /etc/postfix/master.cf
sed -i ‘s|# -o smtpd_sasl_auth_enable=yes| -o smtpd_sasl_auth_enable=yes|’ /etc/postfix/master.cf
sed -i ‘s|# -o smtpd_reject_unlisted_recipient=no| -o smtpd_client_restrictions=permit_sasl_authenticated,reject|’ /etc/postfix/master.cf [/box]
Restart Postfix and Mysql
[box type=”shadow” align=”” class=”” width=””]service postfix restart
mysql_secure_installation
service mysql restart[/box]
Install Softwares Web Server
[box type=”shadow” align=”” class=”” width=””]apt-get install -y apache2 apache2-doc apache2-utils libapache2-mod-php php7.0 php7.0-common
apt-get install -y php7.0-gd php7.0-mysql php7.0-imap php7.0-cli php7.0-cgi libapache2-mod-fcgid
apt-get install -y apache2-suexec-pristine php-pear php-auth php7.0-mcrypt mcrypt imagemagick libruby
apt-get install -y libapache2-mod-python php7.0-curl php7.0-intl php7.0-pspell php7.0-recode php-net-sieve tinymce
apt-get install -y php7.0-sqlite3 php7.0-tidy php7.0-xmlrpc php7.0-opcache php-apcu libapache2-mod-fastcgi php7.0-fpm
apt-get install -y php7.0-xsl memcached php-memcache php-imagick php-gettext php7.0-zip php7.0-mbstring
echo “<IfModule mod_headers.c>
RequestHeader unset Proxy early
</IfModule>” | tee /etc/apache2/conf-available/httpoxy.conf[/box]
Enable Softwares PHP and Apache2 modules
[box type=”shadow” align=”” class=”” width=””]a2enmod suexec rewrite ssl actions include cgi
a2enmod dav_fs dav auth_digest headers actions fastcgi alias
a2enconf httpoxy
apt-get install -y hhvm
echo ‘hhvm.mysql.socket = /var/run/mysqld/mysqld.sock’ >> /etc/hhvm/php.ini
service apache2 restart
[/box]
[box type=”shadow” align=”” class=”” width=””]apt-get install -y certbot[/box]
Install Softwares FTP Server
[box type=”shadow” align=”” class=”” width=””]apt-get install -y pure-ftpd-common pure-ftpd-mysql quota quotatool libclass-dbi-mysql-perl
apt-get install -y bind9 dnsutils vlogger webalizer awstats geoip-database haveged ufw
apt-get install -y build-essential autoconf automake libtool flex bison debhelper binutils
m -f /etc/cron.d/awstats
sed -i ‘s|VIRTUALCHROOT=false|VIRTUALCHROOT=true|’ /etc/default/pure-ftpd-common
sed -i ‘s|application/x-ruby|#application/x-ruby|’ /etc/mime.types
mkdir -p /etc/ssl/private/
openssl req -x509 -nodes -days 7300 -newkey rsa:2048 -keyout /etc/ssl/private/pure-ftpd.pem -out /etc/ssl/private/pure-ftpd.pem
chmod 600 /etc/ssl/private/pure-ftpd.pem
service pure-ftpd-mysql restart
[/box]
Download ISPConfig 3.1.X
[box type=”shadow” align=”” class=”” width=””]cd /tmp
get_isp=https://www.ispconfig.org/downloads/ISPConfig-3-stable.tar.gz
wget -c ${get_isp} tar xvfz $(basename ${get_isp})
cd ispconfig3_install/install && php -q install.php[/box]