Различия

Показаны различия между двумя версиями страницы.

Ссылка на это сравнение

Предыдущая версия справа и слева Предыдущая версия
Следующая версия
Предыдущая версия
debian:server-install-d9 [2018/01/29 19:59] – [Установка] mirocowdebian:server-install-d9 [2018/06/17 20:33] (текущий) – ↷ Операцией перемещения обновлены ссылки 5.9.158.195
Строка 7: Строка 7:
 </code> </code>
  
-  * [[php:php|Установка различных версий PHP]]+  * [[develop:php:php|Установка различных версий PHP]]
  
 ===== Описание ===== ===== Описание =====
Строка 16: Строка 16:
   * Установка автоматического бекапа БД MySQL (https://github.com/Mirocow/mysql_utils.git)   * Установка автоматического бекапа БД MySQL (https://github.com/Mirocow/mysql_utils.git)
   * Устанока скрипта для создания сайта (https://github.com/Mirocow/site-create)   * Устанока скрипта для создания сайта (https://github.com/Mirocow/site-create)
 +  * [[system:exim4]]
  
 ===== Установка ===== ===== Установка =====
Строка 149: Строка 150:
    
 apt-get update && apt-get upgrade -y apt-get update && apt-get upgrade -y
-installpkg -y apt apt-utils wget sudo nano rename debconf-utils pwgen mailutils curl+installpkg apt apt-utils wget sudo nano rename debconf-utils pwgen mailutils curl dirmngr -y
    
 default_pass=$(pwgen -s 18 1 -n -c -s -y) default_pass=$(pwgen -s 18 1 -n -c -s -y)
Строка 157: Строка 158:
 if promptyn "Do you wish to install default programs? [mc, git, etc] " ; then if promptyn "Do you wish to install default programs? [mc, git, etc] " ; then
     info "Install default programs";     info "Install default programs";
-    installpkg -y mc git mercurial bash-completion bzip2 numactl dnsutils+    installpkg mc git mercurial bash-completion bzip2 numactl dnsutils -y
 fi fi
    
 if promptyn "Do you wish to install developers programs? [gcc, g++, etc] "; then if promptyn "Do you wish to install developers programs? [gcc, g++, etc] "; then
     info "Install development soft";     info "Install development soft";
-    installpkg -y checkinstall gcc build-essential g++ libboost-dev libboost-program-options-dev libboost-all-dev libevent-dev uuid-dev clang cmake+    installpkg checkinstall gcc build-essential g++ libboost-dev libboost-program-options-dev libboost-all-dev libevent-dev uuid-dev clang cmake -y
 fi fi
    
 if promptyn "Do you wish to install system monitors? [htop, iptraf] "; then if promptyn "Do you wish to install system monitors? [htop, iptraf] "; then
     info "Install system monitors";     info "Install system monitors";
-    installpkg -y htop iptraf jnettop iftop+    installpkg htop iptraf jnettop iftop -y
 fi fi
    
 if promptyn "Do you wish to uninstall systemd and install systemv? "; then if promptyn "Do you wish to uninstall systemd and install systemv? "; then
-    installpkg -y sysvinit-core sysvinit-utils+    installpkg sysvinit-core sysvinit-utils -y
     cp /usr/share/sysvinit/inittab /etc/inittab     cp /usr/share/sysvinit/inittab /etc/inittab
 fi fi
    
 if promptyn "Do you wish to install FTP Server (PRO-Ftpd)? "; then if promptyn "Do you wish to install FTP Server (PRO-Ftpd)? "; then
-    installpkg -y proftpd+    installpkg proftpd -y
 fi    fi   
    
 if promptyn "Do you wish to install MySql? "; then if promptyn "Do you wish to install MySql? "; then
-    installpkg -y software-properties-common+    installpkg software-properties-common -y
     if promptyn "Do you wish to install MySql (Percona) (y) or Mariadb (n)?"; then     if promptyn "Do you wish to install MySql (Percona) (y) or Mariadb (n)?"; then
    
Строка 192: Строка 193:
         apt-get update         apt-get update
    
-        installpkg -y percona-server-server-5.7 percona-server-client-5.7 percona-server-common-5.7 percona-toolkit -y+        installpkg percona-server-server-5.7 percona-server-client-5.7 percona-server-common-5.7 percona-toolkit -y
         sevice mysql start         sevice mysql start
         check_result $? "mysql start failed"         check_result $? "mysql start failed"
Строка 245: Строка 246:
    
 if promptyn "Do you wish to install PostgreSql? "; then if promptyn "Do you wish to install PostgreSql? "; then
-    installpkg -y postgresql-9.6 postgresql-contrib-9.6+    installpkg postgresql-9.6 postgresql-contrib-9.6 -y
     echo "ALTER USER postgres WITH ENCRYPTED PASSWORD '${default_pass}';" |sudo -u postgres psql     echo "ALTER USER postgres WITH ENCRYPTED PASSWORD '${default_pass}';" |sudo -u postgres psql
     echo "     echo "
Строка 266: Строка 267:
    
     service nginx stop > /dev/null 2>&1     service nginx stop > /dev/null 2>&1
-    installpkg -y nginx+    installpkg nginx -y
     service nginx start     service nginx start
     check_result $? "nginx start failed"     check_result $? "nginx start failed"
Строка 289: Строка 290:
     service php${php_ver}-fpm stop >/dev/null 2>&1     service php${php_ver}-fpm stop >/dev/null 2>&1
    
-    if [ $php_ver -eq 5 ]; then +    if [ "$php_ver" == 5 ]; then 
-          installpkg -y -u -t stable php${php_ver} php${php_ver}-dev php${php_ver}-sqlite php${php_ver}-mcrypt php${php_ver}-xsl php${php_ver}-cli php${php_ver}-common php${php_ver}-mysql php${php_ver}-gd php${php_ver}-fpm php${php_ver}-cgi php-pear php${php_ver}-curl php${php_ver}-pgsql php${php_ver}-mbstring+          installpkg -u -t stable php${php_ver} php${php_ver}-dev php${php_ver}-sqlite php${php_ver}-mcrypt php${php_ver}-xsl php${php_ver}-cli php${php_ver}-common php${php_ver}-mysql php${php_ver}-gd php${php_ver}-fpm php${php_ver}-cgi php-pear php${php_ver}-curl php${php_ver}-pgsql php${php_ver}-mbstring -y
     fi     fi
    
-    if [ $php_ver -eq "7.0" ]; then +    if [ "$php_ver" == "7.0" ]; then 
-          installpkg -y -u -t stable php${php_ver} php${php_ver}-dev php${php_ver}-sqlite php${php_ver}-mcrypt php${php_ver}-xsl php${php_ver}-cli php${php_ver}-common php${php_ver}-mysql php${php_ver}-gd php${php_ver}-fpm php${php_ver}-cgi php-pear php${php_ver}-curl php${php_ver}-redis php${php_ver}-pgsql php${php_ver}-mbstring+          installpkg -u -t stable php${php_ver} php${php_ver}-dev php${php_ver}-sqlite php${php_ver}-mcrypt php${php_ver}-xsl php${php_ver}-cli php${php_ver}-common php${php_ver}-mysql php${php_ver}-gd php${php_ver}-fpm php${php_ver}-cgi php-pear php${php_ver}-curl php${php_ver}-redis php${php_ver}-pgsql php${php_ver}-mbstring -y
     fi     fi
    
-    if [ $php_ver -eq "7.1" ]; then +    if [ "$php_ver" == "7.1" ]; then 
-          installpkg -u -t stable php${php_ver} php${php_ver}-dev php${php_ver}-sqlite php${php_ver}-mcrypt php${php_ver}-xsl php${php_ver}-cli php${php_ver}-common php${php_ver}-mysql php${php_ver}-gd php${php_ver}-fpm php${php_ver}-cgi php-pear php${php_ver}-curl php${php_ver}-redis php${php_ver}-pgsql  php${php_ver}-mbstring+          installpkg -u -t stable php${php_ver} php${php_ver}-dev php${php_ver}-sqlite php${php_ver}-mcrypt php${php_ver}-xsl php${php_ver}-cli php${php_ver}-common php${php_ver}-mysql php${php_ver}-gd php${php_ver}-fpm php${php_ver}-cgi php-pear php${php_ver}-curl php${php_ver}-redis php${php_ver}-pgsql  php${php_ver}-mbstring -y
     fi     fi
    
Строка 326: Строка 327:
    
     service rabbitmq-server start     service rabbitmq-server start
-    installpkg -y rabbitmq-server+    installpkg rabbitmq-server -y
     check_result $? "rabbitmq-server start failed"     check_result $? "rabbitmq-server start failed"
    
Строка 335: Строка 336:
    
 if promptyn "Do you wish to install Redis server? "; then if promptyn "Do you wish to install Redis server? "; then
-    installpkg -y redis-server+    installpkg redis-server -y
     service redis-server start     service redis-server start
     check_result $? "redis-server start failed"     check_result $? "redis-server start failed"
Строка 352: Строка 353:
 if promptyn "Do you wish to install DNS server? "; then if promptyn "Do you wish to install DNS server? "; then
     if promptyn "Do you wish to install bind (y) or pdns (n) server?"; then     if promptyn "Do you wish to install bind (y) or pdns (n) server?"; then
-        installpkg -y bind9 bind9utils bind9-libs+        installpkg bind9 bind9utils bind9-libs -y
         service bind9 start         service bind9 start
         info "Install DNS Server"         info "Install DNS Server"
         set_default_value 'bind' 'true'         set_default_value 'bind' 'true'
     else     else
-        installpkg -y pdns-server pdns-backend-mysql pdns-recursor+        installpkg pdns-server pdns-backend-mysql pdns-recursor -y
         info "Install DNS Server"         info "Install DNS Server"
         set_default_value 'pdns' 'true'         set_default_value 'pdns' 'true'
Строка 364: Строка 365:
    
 if promptyn "Do you wish to install Shorewall? "; then if promptyn "Do you wish to install Shorewall? "; then
-    installpkg -y shorewall+    installpkg shorewall -y
 fi fi
    
 if promptyn "Do you wish to install Postfix/Exim4? "; then if promptyn "Do you wish to install Postfix/Exim4? "; then
-    installpkg -y exim4-daemon-heavy mailutils+    installpkg exim4-daemon-heavy mailutils -y
     service exim4 stop > /dev/null 2>&1     service exim4 stop > /dev/null 2>&1
     gpasswd -a Debian-exim mail     gpasswd -a Debian-exim mail
Строка 397: Строка 398:
     chown -R root:root /etc/dovecot*     chown -R root:root /etc/dovecot*
     service dovecot stop > /dev/null 2>&1     service dovecot stop > /dev/null 2>&1
-    installpkg -y dovecot-imapd dovecot-pop3d dovecot-common+    installpkg dovecot-imapd dovecot-pop3d dovecot-common -y
     service dovecot start     service dovecot start
    
Строка 406: Строка 407:
    
 if promptyn "Do you wish to install fail2ban? "; then if promptyn "Do you wish to install fail2ban? "; then
-    installpkg -y fail2ban+    installpkg fail2ban -y
    
     if [ "$exim" = 'no' ]; then     if [ "$exim" = 'no' ]; then
Строка 423: Строка 424:
    
     apt-get update     apt-get update
-    installpkg -y git+    installpkg git -y
     git clone https://github.com/Mirocow/mysql_utils.git /root/mysql_utils     git clone https://github.com/Mirocow/mysql_utils.git /root/mysql_utils