2022-01-28 17:23:51 +01:00
|
|
|
FROM php:7.4-apache
|
|
|
|
|
|
|
|
ENV SERVERNAME=localhost
|
2022-01-28 18:23:43 +01:00
|
|
|
ENV UPLOAD_MAX_FILESIZE=24M
|
|
|
|
ENV POST_MAX_SIZE=24M
|
|
|
|
ENV MAX_FILE_UPLOADS=201
|
2022-01-28 17:23:51 +01:00
|
|
|
|
|
|
|
RUN apt update && apt install -y gettext-base librsvg2-bin pdftk imagemagick potrace
|
|
|
|
|
|
|
|
COPY . /usr/local/signaturepdf
|
|
|
|
|
|
|
|
RUN chown -R www-data:www-data /usr/local/signaturepdf && chmod 750 -R /usr/local/signaturepdf && \
|
2022-01-28 18:23:43 +01:00
|
|
|
envsubst < /usr/local/signaturepdf/php.ini > /usr/local/etc/php/conf.d/uploads.ini && \
|
|
|
|
envsubst < /usr/local/signaturepdf/apache.conf > /etc/apache2/sites-available/signaturepdf.conf && \
|
2022-01-28 17:23:51 +01:00
|
|
|
a2enmod rewrite && a2ensite signaturepdf
|
|
|
|
|
|
|
|
WORKDIR /usr/local/signaturepdf
|
|
|
|
|
|
|
|
CMD envsubst < /usr/local/signaturepdf/apache.conf > /etc/apache2/sites-available/signaturepdf.conf && \
|
2022-01-28 18:23:43 +01:00
|
|
|
envsubst < /usr/local/signaturepdf/php.ini > /usr/local/etc/php/conf.d/uploads.ini && \
|
2022-01-28 17:23:51 +01:00
|
|
|
chown -R www-data:www-data /usr/local/signaturepdf && chmod 750 -R /usr/local/signaturepdf && \
|
|
|
|
apache2-foreground
|