2018-03-14 16:51:38 -04:00
|
|
|
# Utilize multi-stage build to keep image size down
|
2022-03-18 05:34:35 -04:00
|
|
|
FROM composer:2.0.4 as composer
|
2018-03-14 16:51:38 -04:00
|
|
|
COPY composer.* ./
|
|
|
|
RUN composer install --no-dev --optimize-autoloader --no-progress --no-suggest
|
|
|
|
|
|
|
|
# Build the actual image
|
2022-03-18 05:34:35 -04:00
|
|
|
FROM php:7.1
|
2018-03-14 16:51:38 -04:00
|
|
|
|
2019-06-13 10:16:47 -04:00
|
|
|
ENV LC_ALL C.UTF-8
|
2018-04-14 05:17:40 -04:00
|
|
|
WORKDIR /resume
|
|
|
|
CMD ["/bin/bash"]
|
|
|
|
|
2018-03-14 16:51:38 -04:00
|
|
|
RUN apt-get update \
|
2018-10-17 15:29:43 -04:00
|
|
|
&& apt-get install -qqy --no-install-recommends \
|
2018-03-14 16:51:38 -04:00
|
|
|
# This is for enabling the program to be run with watch
|
|
|
|
procps \
|
|
|
|
# Required to run PDF generation
|
2018-10-17 15:29:43 -04:00
|
|
|
wget apt-utils libjpeg62-turbo libxrender1 xfonts-75dpi xfonts-base fontconfig libxext6 \
|
|
|
|
&& apt-get autoremove \
|
2018-03-14 16:51:38 -04:00
|
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
|
2018-10-17 15:29:43 -04:00
|
|
|
RUN cd /root \
|
2021-02-22 17:35:17 -05:00
|
|
|
&& wget https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox_0.12.6-1.stretch_amd64.deb --no-verbose \
|
|
|
|
&& dpkg -i wkhtmltox_0.12.6-1.stretch_amd64.deb
|
2018-04-14 05:17:40 -04:00
|
|
|
|
|
|
|
# Enables continously calling a command and piping the output to STDOUT, viewable via docker logs
|
|
|
|
RUN printf '#!/bin/bash\nwhile sleep 1; do\n "$@"\ndone' >> /usr/bin/watch-docker \
|
|
|
|
&& chmod +x /usr/bin/watch-docker
|
|
|
|
|
2018-03-14 16:51:38 -04:00
|
|
|
COPY --from=composer /app/vendor /app/vendor
|
|
|
|
COPY . /app
|
|
|
|
|
|
|
|
RUN ln -s /app/bin/md2resume /usr/bin/md2resume
|