2021-07-22 09:12:55 +01:00
|
|
|
FROM php:8-apache
|
2018-06-04 15:20:53 +01:00
|
|
|
|
2020-12-24 18:24:41 +00:00
|
|
|
RUN apt-get update && \
|
|
|
|
apt-get install -y --no-install-recommends \
|
|
|
|
libldb-dev libldap2-dev \
|
|
|
|
libfreetype6-dev \
|
|
|
|
libjpeg-dev \
|
|
|
|
libpng-dev && \
|
2021-03-13 14:11:38 +00:00
|
|
|
rm -rf /var/lib/apt/lists/*
|
2020-12-24 18:24:41 +00:00
|
|
|
|
2021-07-22 09:12:55 +01:00
|
|
|
RUN docker-php-ext-configure gd --with-freetype && \
|
2021-03-13 14:11:38 +00:00
|
|
|
docker-php-ext-install -j$(nproc) gd && \
|
|
|
|
libdir=$(find /usr -name "libldap.so*" | sed -e 's/\/usr\///' -e 's/\/libldap.so//') && \
|
|
|
|
docker-php-ext-configure ldap --with-libdir=$libdir && \
|
|
|
|
docker-php-ext-install -j$(nproc) ldap
|
2018-06-04 15:20:53 +01:00
|
|
|
|
2020-11-28 18:00:01 +00:00
|
|
|
ADD https://github.com/PHPMailer/PHPMailer/archive/v6.2.0.tar.gz /tmp
|
|
|
|
|
2021-03-13 14:11:38 +00:00
|
|
|
RUN a2enmod rewrite ssl && a2dissite 000-default default-ssl
|
2018-06-04 15:20:53 +01:00
|
|
|
|
|
|
|
EXPOSE 80
|
|
|
|
EXPOSE 443
|
|
|
|
|
2020-01-10 12:01:31 +00:00
|
|
|
COPY www/ /opt/ldap_user_manager
|
2020-11-28 18:00:01 +00:00
|
|
|
RUN tar -xzf /tmp/v6.2.0.tar.gz -C /opt && mv /opt/PHPMailer-6.2.0 /opt/PHPMailer
|
|
|
|
|
2020-01-10 12:01:31 +00:00
|
|
|
COPY entrypoint /usr/local/bin/entrypoint
|
|
|
|
RUN chmod a+x /usr/local/bin/entrypoint
|
|
|
|
|
2018-06-04 15:20:53 +01:00
|
|
|
CMD ["apache2-foreground"]
|
|
|
|
ENTRYPOINT ["/usr/local/bin/entrypoint"]
|