diff --git a/.env b/.env index 46d5d300..ddcb61f3 100644 --- a/.env +++ b/.env @@ -1 +1,2 @@ version=6.0.0 +install= diff --git a/5.1.0/php.ini b/5.1.0/php.ini index 2852a748..5cb592c0 100644 --- a/5.1.0/php.ini +++ b/5.1.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.1.0/vtiger-foreground.sh b/5.1.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.1.0/vtiger-foreground.sh +++ b/5.1.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.2.0-RC/php.ini b/5.2.0-RC/php.ini index 2852a748..5cb592c0 100644 --- a/5.2.0-RC/php.ini +++ b/5.2.0-RC/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.2.0-RC/vtiger-foreground.sh b/5.2.0-RC/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.2.0-RC/vtiger-foreground.sh +++ b/5.2.0-RC/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.2.0-VB1/php.ini b/5.2.0-VB1/php.ini index 2852a748..5cb592c0 100644 --- a/5.2.0-VB1/php.ini +++ b/5.2.0-VB1/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.2.0-VB1/vtiger-foreground.sh b/5.2.0-VB1/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.2.0-VB1/vtiger-foreground.sh +++ b/5.2.0-VB1/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.2.0-VB2/php.ini b/5.2.0-VB2/php.ini index 2852a748..5cb592c0 100644 --- a/5.2.0-VB2/php.ini +++ b/5.2.0-VB2/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.2.0-VB2/vtiger-foreground.sh b/5.2.0-VB2/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.2.0-VB2/vtiger-foreground.sh +++ b/5.2.0-VB2/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.2.0/php.ini b/5.2.0/php.ini index 2852a748..5cb592c0 100644 --- a/5.2.0/php.ini +++ b/5.2.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.2.0/vtiger-foreground.sh b/5.2.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.2.0/vtiger-foreground.sh +++ b/5.2.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.2.1/php.ini b/5.2.1/php.ini index 2852a748..5cb592c0 100644 --- a/5.2.1/php.ini +++ b/5.2.1/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.2.1/vtiger-foreground.sh b/5.2.1/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.2.1/vtiger-foreground.sh +++ b/5.2.1/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.3.0-RC/php.ini b/5.3.0-RC/php.ini index 2852a748..5cb592c0 100644 --- a/5.3.0-RC/php.ini +++ b/5.3.0-RC/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.3.0-RC/vtiger-foreground.sh b/5.3.0-RC/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.3.0-RC/vtiger-foreground.sh +++ b/5.3.0-RC/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.3.0/php.ini b/5.3.0/php.ini index 2852a748..5cb592c0 100644 --- a/5.3.0/php.ini +++ b/5.3.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.3.0/vtiger-foreground.sh b/5.3.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.3.0/vtiger-foreground.sh +++ b/5.3.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.4.0-RC/php.ini b/5.4.0-RC/php.ini index 2852a748..5cb592c0 100644 --- a/5.4.0-RC/php.ini +++ b/5.4.0-RC/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.4.0-RC/vtiger-foreground.sh b/5.4.0-RC/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.4.0-RC/vtiger-foreground.sh +++ b/5.4.0-RC/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/5.4.0/php.ini b/5.4.0/php.ini index 2852a748..5cb592c0 100644 --- a/5.4.0/php.ini +++ b/5.4.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/5.4.0/vtiger-foreground.sh b/5.4.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/5.4.0/vtiger-foreground.sh +++ b/5.4.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.0.0-Beta/Dockerfile b/6.0.0-Beta/Dockerfile index 61df9924..a126ea5f 100644 --- a/6.0.0-Beta/Dockerfile +++ b/6.0.0-Beta/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer='Francesco Bianco ' -ENV VT_VERSION=6.0.0-Beta \ +ENV VT_INSTALL=1 \ + VT_VERSION=6.0.0-Beta \ VT_DOWNLOAD=http://sourceforge.net/projects/vtigercrm/files/vtiger%20CRM%206.0%20Beta/Core%20Product/vtigercrm-6.0Beta.tar.gz \ DATABASE_PACKAGE=mariadb-server-10.1 \ COMPOSER_ALLOW_SUPERUSER=1 \ @@ -10,7 +11,7 @@ ENV VT_VERSION=6.0.0-Beta \ WORKDIR /usr/src/vtiger COPY php.ini /usr/local/etc/php/ -COPY vtiger.json /usr/src/vtiger/ +COPY .symvol /usr/src/vtiger/ COPY vtiger-ssl.* /etc/apache2/ssl/ COPY 000-default.conf /etc/apache2/sites-available/ @@ -18,9 +19,9 @@ RUN apt-get update && \ apt-get install --no-install-recommends -y zlib1g-dev libc-client-dev libkrb5-dev cron rsyslog unzip && \ docker-php-ext-configure imap --with-kerberos --with-imap-ssl && \ docker-php-ext-install imap exif mysql mysqli pdo pdo_mysql zip && \ + curl -sL https://javanile.github.io/symvol/setup.sh?v=0.0.2 | bash - && \ curl -o composer.phar -sL https://getcomposer.org/composer.phar && \ - php composer.phar --ansi require javanile/http-robot:0.0.2 && \ - php composer.phar --ansi global require javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ + php composer.phar --ansi global require javanile/http-robot:0.0.2 javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ usermod -u 1000 www-data && groupmod -g 1000 www-data && \ echo "ServerName localhost" >> /etc/apache2/apache2.conf && \ curl -o vtiger.tar.gz -sL "$VT_DOWNLOAD" && tar -xzf vtiger.tar.gz && rm vtiger.tar.gz && \ @@ -28,19 +29,21 @@ RUN apt-get update && \ vtiger permissions --fix && \ a2enmod ssl && a2enmod rewrite && \ apt-get clean && php composer.phar clearcache && \ + mv .symvol /var/www/html && \ + mkdir -p volume /var/lib/vtiger && \ rm -rf composer.phar /tmp/* /var/tmp/* /var/lib/apt/lists/* /etc/cron.* -COPY develop-install.sh /usr/local/bin/ -RUN chmod +x /usr/local/bin/develop-install.sh && develop-install.sh COPY vtiger-*.sh /usr/local/bin/ COPY vtiger-*.php /usr/src/vtiger/ COPY crontab /etc/cron.d/crontab -RUN chmod +x /usr/local/bin/vtiger-*.sh && vtiger-install.sh --assert-mysql --dump --remove-mysql COPY LoggerManager.php /var/www/html/libraries/log4php/ -COPY config.inc.php config.performance.php /var/www/html/ +COPY vtiger.json config.inc.php /usr/src/vtiger/ +COPY config.performance.php loading.php /var/www/html/ -VOLUME ["/var/www/html/storage", "/var/www/html/logs"] +RUN sed -i 's/^error_reporting = .*$/error_reporting = E_ALL \& ~E_WARNING \& ~E_NOTICE \& ~E_DEPRECATED \& ~E_STRICT/' /usr/local/etc/php/php.ini + +VOLUME ["/var/lib/vtiger"] WORKDIR /app diff --git a/6.0.0-Beta/php.ini b/6.0.0-Beta/php.ini index 2852a748..5cb592c0 100644 --- a/6.0.0-Beta/php.ini +++ b/6.0.0-Beta/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.0.0-Beta/vtiger-foreground.sh b/6.0.0-Beta/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.0.0-Beta/vtiger-foreground.sh +++ b/6.0.0-Beta/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.0.0-RC/Dockerfile b/6.0.0-RC/Dockerfile index 24c33ce4..3e90ee62 100644 --- a/6.0.0-RC/Dockerfile +++ b/6.0.0-RC/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer='Francesco Bianco ' -ENV VT_VERSION=6.0.0-RC \ +ENV VT_INSTALL=1 \ + VT_VERSION=6.0.0-RC \ VT_DOWNLOAD=http://sourceforge.net/projects/vtigercrm/files/vtiger%20CRM%206.0%20RC/Core%20Product/vtigercrm-6.0.0rc.tar.gz \ DATABASE_PACKAGE=mariadb-server-10.1 \ COMPOSER_ALLOW_SUPERUSER=1 \ @@ -10,7 +11,7 @@ ENV VT_VERSION=6.0.0-RC \ WORKDIR /usr/src/vtiger COPY php.ini /usr/local/etc/php/ -COPY vtiger.json /usr/src/vtiger/ +COPY .symvol /usr/src/vtiger/ COPY vtiger-ssl.* /etc/apache2/ssl/ COPY 000-default.conf /etc/apache2/sites-available/ @@ -18,9 +19,9 @@ RUN apt-get update && \ apt-get install --no-install-recommends -y zlib1g-dev libc-client-dev libkrb5-dev cron rsyslog unzip && \ docker-php-ext-configure imap --with-kerberos --with-imap-ssl && \ docker-php-ext-install imap exif mysql mysqli pdo pdo_mysql zip && \ + curl -sL https://javanile.github.io/symvol/setup.sh?v=0.0.2 | bash - && \ curl -o composer.phar -sL https://getcomposer.org/composer.phar && \ - php composer.phar --ansi require javanile/http-robot:0.0.2 && \ - php composer.phar --ansi global require javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ + php composer.phar --ansi global require javanile/http-robot:0.0.2 javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ usermod -u 1000 www-data && groupmod -g 1000 www-data && \ echo "ServerName localhost" >> /etc/apache2/apache2.conf && \ curl -o vtiger.tar.gz -sL "$VT_DOWNLOAD" && tar -xzf vtiger.tar.gz && rm vtiger.tar.gz && \ @@ -28,19 +29,21 @@ RUN apt-get update && \ vtiger permissions --fix && \ a2enmod ssl && a2enmod rewrite && \ apt-get clean && php composer.phar clearcache && \ + mv .symvol /var/www/html && \ + mkdir -p volume /var/lib/vtiger && \ rm -rf composer.phar /tmp/* /var/tmp/* /var/lib/apt/lists/* /etc/cron.* -COPY develop-install.sh /usr/local/bin/ -RUN chmod +x /usr/local/bin/develop-install.sh && develop-install.sh COPY vtiger-*.sh /usr/local/bin/ COPY vtiger-*.php /usr/src/vtiger/ COPY crontab /etc/cron.d/crontab -RUN chmod +x /usr/local/bin/vtiger-*.sh && vtiger-install.sh --assert-mysql --dump --remove-mysql COPY LoggerManager.php /var/www/html/libraries/log4php/ -COPY config.inc.php config.performance.php /var/www/html/ +COPY vtiger.json config.inc.php /usr/src/vtiger/ +COPY config.performance.php loading.php /var/www/html/ -VOLUME ["/var/www/html/storage", "/var/www/html/logs"] +RUN sed -i 's/^error_reporting = .*$/error_reporting = E_ALL \& ~E_WARNING \& ~E_NOTICE \& ~E_DEPRECATED \& ~E_STRICT/' /usr/local/etc/php/php.ini + +VOLUME ["/var/lib/vtiger"] WORKDIR /app diff --git a/6.0.0-RC/php.ini b/6.0.0-RC/php.ini index 2852a748..5cb592c0 100644 --- a/6.0.0-RC/php.ini +++ b/6.0.0-RC/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.0.0-RC/vtiger-foreground.sh b/6.0.0-RC/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.0.0-RC/vtiger-foreground.sh +++ b/6.0.0-RC/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.0.0/Dockerfile b/6.0.0/Dockerfile index d7ff1b98..86211113 100644 --- a/6.0.0/Dockerfile +++ b/6.0.0/Dockerfile @@ -1,61 +1,57 @@ FROM php:5.6.40-apache -LABEL maintainer="Francesco Bianco " +LABEL maintainer='Francesco Bianco ' -ENV LAYER_BREAK=true -ENV VT_VERSION="6.0.0" \ - DATABASE_PACKAGE="mysql-server-5.5" \ - PATH="/root/.composer/vendor/bin:$PATH" +ENV VT_INSTALL=1 \ + VT_VERSION=6.0.0 \ + VT_DOWNLOAD=https://github.com/javanile/vtiger-core/archive/6.0.0.tar.gz \ + DATABASE_PACKAGE=mariadb-server-10.1 \ + COMPOSER_ALLOW_SUPERUSER=1 \ + PATH=/root/.composer/vendor/bin:$PATH + +WORKDIR /usr/src/vtiger COPY php.ini /usr/local/etc/php/ -COPY vtiger.json .symvol /usr/src/vtiger/ +COPY .symvol /usr/src/vtiger/ COPY vtiger-ssl.* /etc/apache2/ssl/ COPY 000-default.conf /etc/apache2/sites-available/ RUN apt-get update && \ - apt-get install --no-install-recommends -y zlib1g-dev libc-client-dev libkrb5-dev libfreetype6-dev libjpeg62-turbo-dev libpng-dev libxml2-dev cron rsyslog zip unzip socat vim nano && \ - docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ && \ + apt-get install --no-install-recommends -y zlib1g-dev libc-client-dev libkrb5-dev cron rsyslog unzip && \ docker-php-ext-configure imap --with-kerberos --with-imap-ssl && \ - docker-php-ext-install imap exif mysqli pdo pdo_mysql zip gd xml && \ - echo "cron.* /var/log/cron.log" >> /etc/rsyslog.conf && rm -fr /etc/cron.* && mkdir /etc/cron.d && ${LAYER_BREAK} -RUN curl -o composer -sL https://getcomposer.org/composer.phar && \ - php composer global require javanile/http-robot:0.0.2 javanile/mysql-import:0.0.15 javanile/vtiger-cli:0.0.4 && \ - php composer clearcache && rm composer && ${LAYER_BREAK} + docker-php-ext-install imap exif mysql mysqli pdo pdo_mysql zip && ${LAYER_BREAK} RUN curl -sL https://javanile.github.io/symvol/setup.sh?v=0.0.2 | bash - && ${LAYER_BREAK} -RUN usermod -u 1000 www-data && groupmod -g 1000 www-data && \ +RUN curl -o composer.phar -sL https://getcomposer.org/composer.phar && \ + php composer.phar --ansi global require javanile/http-robot:0.0.2 javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ + usermod -u 1000 www-data && groupmod -g 1000 www-data && \ echo "ServerName localhost" >> /etc/apache2/apache2.conf && \ - a2enmod ssl && a2enmod rewrite && ${LAYER_BREAK} -RUN cd /usr/src/vtiger && \ - curl -o vtiger.tar.gz -L "https://github.com/javanile/vtiger-core/archive/6.0.0.tar.gz" && \ - tar -xzf vtiger.tar.gz && \ - rm vtiger.tar.gz && \ - rm -fr /var/www/html && \ - mv "vtiger-core-6.0.0" /var/www/html && \ + curl -o vtiger.tar.gz -sL "$VT_DOWNLOAD" && tar -xzf vtiger.tar.gz && rm vtiger.tar.gz && \ + rm -fr /var/www/html && mv "vtiger-core-6.0.0" /var/www/html && \ vtiger permissions --fix && \ - mv .symvol /var/www/html && \ + a2enmod ssl && a2enmod rewrite && \ + apt-get clean && php composer.phar clearcache && ${LAYER_BREAK} +RUN mv .symvol /var/www/html && \ mkdir -p volume /var/lib/vtiger && ${LAYER_BREAK} -RUN apt-get clean && rm -rf /tmp/* /var/tmp/* /var/lib/apt/lists/* +RUN rm -rf composer.phar /tmp/* /var/tmp/* /var/lib/apt/lists/* /etc/cron.* COPY vtiger-*.sh /usr/local/bin/ COPY vtiger-*.php /usr/src/vtiger/ - -RUN vtiger-install.sh --install-mysql --assert-mysql --dump --remove-mysql && ${LAYER_BREAK} -RUN cd /var/www/html/vtlib/Vtiger/ && \ - sed -e 's!realpath(!__realpath__(!' -ri Utils.php Deprecated.php && \ - symvol move /var/www/html /usr/src/vtiger/volume +COPY crontab /etc/cron.d/crontab COPY LoggerManager.php /var/www/html/libraries/log4php/ -COPY config.inc.php config.performance.php loading.php /var/www/html/ -COPY crontab /etc/ +COPY vtiger.json config.inc.php /usr/src/vtiger/ +COPY config.performance.php loading.php /var/www/html/ + +RUN sed -i 's/^error_reporting = .*$/error_reporting = E_ALL \& ~E_WARNING \& ~E_NOTICE \& ~E_DEPRECATED \& ~E_STRICT/' /usr/local/etc/php/php.ini VOLUME ["/var/lib/vtiger"] WORKDIR /app -ENV VT_ADMIN_USER="admin" \ - VT_ADMIN_PASSWORD="admin" \ - VT_ADMIN_EMAIL="admin@localhost.lan" \ - VT_CURRENCY_NAME="USA, Dollars" \ - MYSQL_HOST="mysql" \ - MYSQL_DATABASE="vtiger" +ENV VT_ADMIN_USER='admin' \ + VT_ADMIN_PASSWORD='admin' \ + VT_ADMIN_EMAIL='admin@localhost.lan' \ + VT_CURRENCY_NAME='USA, Dollars' \ + MYSQL_HOST='mysql' \ + MYSQL_DATABASE='vtiger' CMD ["vtiger-foreground.sh"] diff --git a/6.0.0/php.ini b/6.0.0/php.ini index 2852a748..5cb592c0 100644 --- a/6.0.0/php.ini +++ b/6.0.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.0.0/vtiger-foreground.sh b/6.0.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.0.0/vtiger-foreground.sh +++ b/6.0.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.1.0-Beta/Dockerfile b/6.1.0-Beta/Dockerfile index 75267b6f..b9f61d33 100644 --- a/6.1.0-Beta/Dockerfile +++ b/6.1.0-Beta/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="6.1.0-Beta" \ +ENV VT_INSTALL=1 \ + VT_VERSION="6.1.0-Beta" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/6.1.0-Beta/php.ini b/6.1.0-Beta/php.ini index 2852a748..5cb592c0 100644 --- a/6.1.0-Beta/php.ini +++ b/6.1.0-Beta/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.1.0-Beta/vtiger-foreground.sh b/6.1.0-Beta/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.1.0-Beta/vtiger-foreground.sh +++ b/6.1.0-Beta/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.1.0/Dockerfile b/6.1.0/Dockerfile index 47760754..2271f85b 100644 --- a/6.1.0/Dockerfile +++ b/6.1.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="6.1.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="6.1.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/6.1.0/php.ini b/6.1.0/php.ini index 2852a748..5cb592c0 100644 --- a/6.1.0/php.ini +++ b/6.1.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.1.0/vtiger-foreground.sh b/6.1.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.1.0/vtiger-foreground.sh +++ b/6.1.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.2.0/Dockerfile b/6.2.0/Dockerfile index a3947b08..66850ae4 100644 --- a/6.2.0/Dockerfile +++ b/6.2.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="6.2.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="6.2.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/6.2.0/php.ini b/6.2.0/php.ini index 2852a748..5cb592c0 100644 --- a/6.2.0/php.ini +++ b/6.2.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.2.0/vtiger-foreground.sh b/6.2.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.2.0/vtiger-foreground.sh +++ b/6.2.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.3.0/Dockerfile b/6.3.0/Dockerfile index 52c15972..5bdd6b77 100644 --- a/6.3.0/Dockerfile +++ b/6.3.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="6.3.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="6.3.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/6.3.0/php.ini b/6.3.0/php.ini index 2852a748..5cb592c0 100644 --- a/6.3.0/php.ini +++ b/6.3.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.3.0/vtiger-foreground.sh b/6.3.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.3.0/vtiger-foreground.sh +++ b/6.3.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.4.0/Dockerfile b/6.4.0/Dockerfile index ddf4e85b..4916bf88 100644 --- a/6.4.0/Dockerfile +++ b/6.4.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="6.4.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="6.4.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/6.4.0/php.ini b/6.4.0/php.ini index 2852a748..5cb592c0 100644 --- a/6.4.0/php.ini +++ b/6.4.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.4.0/vtiger-foreground.sh b/6.4.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.4.0/vtiger-foreground.sh +++ b/6.4.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/6.5.0/Dockerfile b/6.5.0/Dockerfile index ac69e453..02c80069 100644 --- a/6.5.0/Dockerfile +++ b/6.5.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:5.6.40-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="6.5.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="6.5.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/6.5.0/php.ini b/6.5.0/php.ini index 2852a748..5cb592c0 100644 --- a/6.5.0/php.ini +++ b/6.5.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/6.5.0/vtiger-foreground.sh b/6.5.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/6.5.0/vtiger-foreground.sh +++ b/6.5.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/7.0.0/Dockerfile b/7.0.0/Dockerfile index f831fd78..53348b17 100644 --- a/7.0.0/Dockerfile +++ b/7.0.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:7.0.33-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="7.0.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="7.0.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/7.0.0/php.ini b/7.0.0/php.ini index 2852a748..5cb592c0 100644 --- a/7.0.0/php.ini +++ b/7.0.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/7.0.0/vtiger-foreground.sh b/7.0.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/7.0.0/vtiger-foreground.sh +++ b/7.0.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/7.0.1/Dockerfile b/7.0.1/Dockerfile index d2031643..09b7c9a6 100644 --- a/7.0.1/Dockerfile +++ b/7.0.1/Dockerfile @@ -1,7 +1,8 @@ FROM php:7.0.33-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="7.0.1" \ +ENV VT_INSTALL=1 \ + VT_VERSION="7.0.1" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/7.0.1/php.ini b/7.0.1/php.ini index 2852a748..5cb592c0 100644 --- a/7.0.1/php.ini +++ b/7.0.1/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/7.0.1/vtiger-foreground.sh b/7.0.1/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/7.0.1/vtiger-foreground.sh +++ b/7.0.1/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/7.1.0-RC/Dockerfile b/7.1.0-RC/Dockerfile index cdd4782c..920dbb20 100644 --- a/7.1.0-RC/Dockerfile +++ b/7.1.0-RC/Dockerfile @@ -1,7 +1,8 @@ FROM php:7.0.33-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="7.1.0-RC" \ +ENV VT_INSTALL=1 \ + VT_VERSION="7.1.0-RC" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/7.1.0-RC/php.ini b/7.1.0-RC/php.ini index 2852a748..5cb592c0 100644 --- a/7.1.0-RC/php.ini +++ b/7.1.0-RC/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/7.1.0-RC/vtiger-foreground.sh b/7.1.0-RC/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/7.1.0-RC/vtiger-foreground.sh +++ b/7.1.0-RC/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/7.1.0/Dockerfile b/7.1.0/Dockerfile index 706afc47..d7a17e18 100644 --- a/7.1.0/Dockerfile +++ b/7.1.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:7.0.33-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="7.1.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="7.1.0" \ DATABASE_PACKAGE="mariadb-server-10.1" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/7.1.0/php.ini b/7.1.0/php.ini index 2852a748..5cb592c0 100644 --- a/7.1.0/php.ini +++ b/7.1.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/7.1.0/vtiger-foreground.sh b/7.1.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/7.1.0/vtiger-foreground.sh +++ b/7.1.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/7.2.0/Dockerfile b/7.2.0/Dockerfile index 136ac47e..6d5169e2 100644 --- a/7.2.0/Dockerfile +++ b/7.2.0/Dockerfile @@ -1,7 +1,8 @@ FROM php:7.3.12-apache LABEL maintainer="Francesco Bianco " -ENV VT_VERSION="7.2.0" \ +ENV VT_INSTALL=1 \ + VT_VERSION="7.2.0" \ DATABASE_PACKAGE="mariadb-server-10.3" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/7.2.0/php.ini b/7.2.0/php.ini index 2852a748..5cb592c0 100644 --- a/7.2.0/php.ini +++ b/7.2.0/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/7.2.0/vtiger-foreground.sh b/7.2.0/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/7.2.0/vtiger-foreground.sh +++ b/7.2.0/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..." diff --git a/Dockerfile.main.template b/Dockerfile.main.template index 27581e85..6cfde9ed 100644 --- a/Dockerfile.main.template +++ b/Dockerfile.main.template @@ -2,7 +2,8 @@ FROM php:%%PHP_VERSION%%-apache LABEL maintainer="Francesco Bianco " ENV LAYER_BREAK=true -ENV VT_VERSION="%%VT_VERSION%%" \ +ENV VT_INSTALL=1 \ + VT_VERSION="%%VT_VERSION%%" \ DATABASE_PACKAGE="%%DATABASE_PACKAGE%%" \ PATH="/root/.composer/vendor/bin:$PATH" diff --git a/Dockerfile.robust.template b/Dockerfile.robust.template index f083e4ee..568079c9 100644 --- a/Dockerfile.robust.template +++ b/Dockerfile.robust.template @@ -1,7 +1,8 @@ FROM php:%%PHP_VERSION%%-apache LABEL maintainer='Francesco Bianco ' -ENV VT_VERSION=%%VT_VERSION%% \ +ENV VT_INSTALL=1 \ + VT_VERSION=%%VT_VERSION%% \ VT_DOWNLOAD=%%VT_DOWNLOAD%% \ DATABASE_PACKAGE=%%DATABASE_PACKAGE%% \ COMPOSER_ALLOW_SUPERUSER=1 \ @@ -10,29 +11,31 @@ ENV VT_VERSION=%%VT_VERSION%% \ WORKDIR /usr/src/vtiger COPY php.ini /usr/local/etc/php/ -COPY vtiger.json /usr/src/vtiger/ +COPY .symvol /usr/src/vtiger/ COPY vtiger-ssl.* /etc/apache2/ssl/ COPY 000-default.conf /etc/apache2/sites-available/ RUN apt-get update && \ apt-get install --no-install-recommends -y zlib1g-dev libc-client-dev libkrb5-dev cron rsyslog unzip && \ docker-php-ext-configure imap --with-kerberos --with-imap-ssl && \ - docker-php-ext-install imap exif mysql mysqli pdo pdo_mysql zip && \ - curl -o composer.phar -sL https://getcomposer.org/composer.phar && \ - php composer.phar --ansi require javanile/http-robot:0.0.2 && \ - php composer.phar --ansi global require javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ + docker-php-ext-install imap exif mysql mysqli pdo pdo_mysql zip && ${LAYER_BREAK} +RUN curl -sL https://javanile.github.io/symvol/setup.sh?v=0.0.2 | bash - && ${LAYER_BREAK} +RUN curl -o composer.phar -sL https://getcomposer.org/composer.phar && \ + php composer.phar --ansi global require javanile/http-robot:0.0.2 javanile/mysql-import:0.0.11 javanile/vtiger-cli:0.0.3 && \ usermod -u 1000 www-data && groupmod -g 1000 www-data && \ echo "ServerName localhost" >> /etc/apache2/apache2.conf && \ curl -o vtiger.tar.gz -sL "$VT_DOWNLOAD" && tar -xzf vtiger.tar.gz && rm vtiger.tar.gz && \ rm -fr /var/www/html && mv "%%VT_DIRECTORY%%" /var/www/html && \ vtiger permissions --fix && \ a2enmod ssl && a2enmod rewrite && \ - apt-get clean && php composer.phar clearcache && \ - rm -rf composer.phar /tmp/* /var/tmp/* /var/lib/apt/lists/* /etc/cron.* + apt-get clean && php composer.phar clearcache && ${LAYER_BREAK} +RUN mv .symvol /var/www/html && \ + mkdir -p volume /var/lib/vtiger && ${LAYER_BREAK} +RUN rm -rf composer.phar /tmp/* /var/tmp/* /var/lib/apt/lists/* /etc/cron.* ## @block: develop -COPY develop-install.sh /usr/local/bin/ -RUN chmod +x /usr/local/bin/develop-install.sh && develop-install.sh +#COPY develop-install.sh /usr/local/bin/ +#RUN chmod +x /usr/local/bin/develop-install.sh && develop-install.sh ## @endblock COPY vtiger-*.sh /usr/local/bin/ COPY vtiger-*.php /usr/src/vtiger/ @@ -40,16 +43,19 @@ COPY crontab /etc/cron.d/crontab ## @block: develop #RUN chmod +x /usr/local/bin/vtiger-*.sh -RUN chmod +x /usr/local/bin/vtiger-*.sh && vtiger-install.sh --assert-mysql --dump --remove-mysql +#RUN chmod +x /usr/local/bin/vtiger-*.sh && vtiger-install.sh --assert-mysql --dump --remove-mysql ## @block: production #RUN chmod +x /usr/local/bin/vtiger-*.sh #RUN chmod +x /usr/local/bin/vtiger-*.sh && vtiger-install.sh --install-mysql --assert-mysql --dump --remove-mysql ## @endblock COPY LoggerManager.php /var/www/html/libraries/log4php/ -COPY config.inc.php config.performance.php /var/www/html/ +COPY vtiger.json config.inc.php /usr/src/vtiger/ +COPY config.performance.php loading.php /var/www/html/ #COPY config.performance.php /var/www/html/ -VOLUME ["/var/www/html/storage", "/var/www/html/logs"] +RUN sed -i 's/^error_reporting = .*$/error_reporting = E_ALL \& ~E_WARNING \& ~E_NOTICE \& ~E_DEPRECATED \& ~E_STRICT/' /usr/local/etc/php/php.ini + +VOLUME ["/var/lib/vtiger"] WORKDIR /app diff --git a/README.md b/README.md index 26e2b0b8..a194e2d1 100644 --- a/README.md +++ b/README.md @@ -51,3 +51,9 @@ improve marketing reach, and deliver great customer service. Try it free with Do ```bash ./develop.sh ``` + +## Error reporting + +```ini +error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT +``` diff --git a/docker-compose.yml b/docker-compose.yml index 4fe52b69..8fe0f7d6 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,7 +5,8 @@ services: vtiger: build: ${version} environment: - - VT_DEBUG=true + - VT_DEBUG=false + - VT_INSTALL=${install} - MYSQL_ROOT_PASSWORD=secret ports: - 20080:80 diff --git a/php.ini b/php.ini index 2852a748..5cb592c0 100644 --- a/php.ini +++ b/php.ini @@ -7,7 +7,6 @@ log_errors = On short_open_tag = Off error_log = /var/www/html/logs/php.log error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED -;error_reporting = E_WARNING & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT max_execution_time = 0 memory_limit = 4G post_max_size = 4G diff --git a/php0.ini b/php0.ini new file mode 100644 index 00000000..2dfa7bd2 --- /dev/null +++ b/php0.ini @@ -0,0 +1,13 @@ +display_startup_errors = On +display_errors = On +html_errors = On +docref_root = 0 +docref_ext = 0 +log_errors = On +short_open_tag = Off +error_log = /var/www/html/logs/php.log +error_reporting = E_ALL & ~E_WARNING +max_execution_time = 0 +memory_limit = 4G +post_max_size = 4G +upload_max_filesize = 4G diff --git a/versions.sh b/versions.sh index ab4aaea6..9b2cda40 100644 --- a/versions.sh +++ b/versions.sh @@ -20,7 +20,7 @@ versions=( ["6.2.0"]=main,5.6.40,mariadb-server-10.1,sourceforge_vtiger,vtigercrm,vtiger%20CRM%206.2.0/Core%20Product/vtigercrm6.2.0.tar.gz ["6.1.0"]=main,5.6.40,mariadb-server-10.1,sourceforge_vtiger,vtigercrm,vtiger%20CRM%206.1.0/Core%20Product/vtigercrm6.1.0.tar.gz ["6.1.0-Beta"]=main,5.6.40,mariadb-server-10.1,sourceforge_vtiger,vtigercrm,Vtiger%20CRM%206.1.0%20Beta/Core%20Product/vtigercrm-6.1.0-ea.tar.gz - ["6.0.0"]=main,5.6.40,mysql-server-5.5,github_javanile,vtiger-core-6.0.0,6.0.0.tar.gz + ["6.0.0"]=robust,5.6.40,mariadb-server-10.1,github_javanile,vtiger-core-6.0.0,6.0.0.tar.gz ["6.0.0-RC"]=robust,5.6.40,mariadb-server-10.1,sourceforge_vtiger,vtigerCRM,vtiger%20CRM%206.0%20RC/Core%20Product/vtigercrm-6.0.0rc.tar.gz ["6.0.0-Beta"]=robust,5.6.40,mariadb-server-10.1,sourceforge_vtiger,vtigerCRM,vtiger%20CRM%206.0%20Beta/Core%20Product/vtigercrm-6.0Beta.tar.gz ["5.4.0"]=stale,5.3.29,mariadb-server-10.3,sourceforge_vtiger,vtigercrm,vtiger%20CRM%205.4.0/Core%20Product/vtigercrm-5.4.0.tar.gz diff --git a/vtiger-foreground.sh b/vtiger-foreground.sh index 54ceb223..aa4a10fa 100755 --- a/vtiger-foreground.sh +++ b/vtiger-foreground.sh @@ -30,11 +30,19 @@ service apache2 start >/dev/null 2>&1 printenv | sed 's/^\(.*\)$/export \1/g' | grep -E '^export MYSQL_|^export VT_' > /run/crond.env ## import database using environment variables -cd /usr/src/vtiger -loading "Waiting for database..." -echo "[vtiger] Waiting for available database..." -echo -n "[vtiger] " && mysql-import --do-while vtiger.sql -#php vtiger-startup.php +if [[ -n "${VT_INSTALL}" ]]; then + cd /usr/src/vtiger + loading "Waiting for database..." + echo "[vtiger] Waiting for available database..." + echo -n "[vtiger] " && mysql-import --do-while vtiger.sql + #php vtiger-startup.php + + ## Remove default config.inc.php if VT_INSTALL is false + if [[ -f /var/www/html/config.inc.php ]]; then + echo "[vtiger] Create configuration files..." + cp config.inc.php /var/www/html/config.inc.php + fi +fi ## fill current mounted volume loading "Waiting for volume preparation..."