Skip to content
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
59 lines (46 sloc) 2.52 KB
FROM php:7.2-fpm
ARG email
ARG mail_host
ARG calendar_domain
ARG mail_username
ARG mail_password
RUN apt-get update && apt-get install -y --no-install-recommends \
curl \
unzip \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
RUN curl -O && \
bunzip2 ssmtp_2.64.orig.tar.bz2 && \
tar -xvf ssmtp_2.64.orig.tar && \
cd ssmtp-2.64 && ./configure && make && \
echo "echo 'Skipping config generation'" > generate_config && make install && \
cd .. && rm -rf ssmtp-2.64 && rm ssmtp_2.64.orig.tar
COPY configurations/baikal/php-mail.ini /usr/local/etc/php/conf.d/mail.ini
RUN echo "root=${email}\nmailhub=${mail_host}\nrewriteDomain= \
\nhostname=${calendar_domain}\nFromLineOverride=YES \
\nAuthUser=${mail_username}\nAuthPass=${mail_password}\n" > /usr/local/etc/ssmtp/ssmtp.conf
RUN docker-php-ext-configure pdo_mysql --with-pdo-mysql=mysqlnd \
&& docker-php-ext-install pdo_mysql \
&& docker-php-source delete
### "Baikal-installation"
RUN cd /tmp/ && curl --silent -LO \
&& unzip /tmp/ -d /var/www/ \
&& rm -Rvf /var/www/Baikal-0.6.0/Specific/db/.empty && rm -f /tmp/
RUN mv /var/www/Baikal-0.6.0 /var/www/calendar_server
WORKDIR /var/www/calendar_server
# Scheduling and email delivery. See:
# This needs to be patched on the Baikal start up Server.php, NOT in the SabreDAV server.
COPY configurations/baikal/Server.php Core/Frameworks/Baikal/Core/Server.php
# The Baikal administration wizard creates these two config files when first run. Preserve them
# and save them to the resources/ directory. These files must be preserved for upgrades.
# Both files are already in the .gitignore file.
COPY configurations/baikal/config.php /var/www/calendar_server/Specific/
COPY configurations/baikal/config.system.php /var/www/calendar_server/Specific/
# While doing this, we _must_ create the tables for Baikal before hand, if they don't exist yet
RUN touch /var/www/calendar_server/Specific/INSTALL_DISABLED
RUN curl -sS | php -- --install-dir=/usr/local/bin --filename=composer
RUN composer install --no-ansi --no-dev --no-interaction --no-progress --optimize-autoloader
RUN chown -Rf www-data:www-data Specific
RUN chmod -Rf g+w Specific
You can’t perform that action at this time.