FROM php:7-apache-stretch

ADD https://raw.githubusercontent.com/docker-gcf/docker-gcf/v1.5.0/setup.sh /tmp/docker-utils-setup.sh
RUN sh /tmp/docker-utils-setup.sh
CMD ["gcf-entrypoint", "apache2-foreground"]

RUN pkgs-install libpq-dev libc-client-dev libkrb5-dev
RUN docker-php-ext-configure imap --with-kerberos --with-imap-ssl
RUN docker-php-ext-install pdo pdo_pgsql pgsql imap

COPY ./postfixadmin-3.2.2/ /var/www/html/

COPY ./config /etc/salt/base/
