|
|
@ -27,6 +27,31 @@ COPY --from=composer /app/composer.lock /app/
|
|
|
|
|
|
|
|
|
|
|
|
RUN find /app/storage/ -type f -not -name VERSION -exec rm {} \;
|
|
|
|
RUN find /app/storage/ -type f -not -name VERSION -exec rm {} \;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Fetch supercronic
|
|
|
|
|
|
|
|
FROM alpine as supercronic
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ENV SUPERCRONIC_URL=https://github.com/aptible/supercronic/releases/download/v0.1.12/supercronic-linux-amd64 \
|
|
|
|
|
|
|
|
SUPERCRONIC=supercronic-linux-amd64 \
|
|
|
|
|
|
|
|
SUPERCRONIC_SHA1SUM=048b95b48b708983effb2e5c935a1ef8483d9e3e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
RUN apk add --no-cache curl \
|
|
|
|
|
|
|
|
&& curl -fsSLO "$SUPERCRONIC_URL" \
|
|
|
|
|
|
|
|
&& echo "${SUPERCRONIC_SHA1SUM} ${SUPERCRONIC}" | sha1sum -c - \
|
|
|
|
|
|
|
|
&& chmod +x "$SUPERCRONIC" \
|
|
|
|
|
|
|
|
&& mv "$SUPERCRONIC" "/usr/local/bin/${SUPERCRONIC}"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Build a container for running tasks
|
|
|
|
|
|
|
|
FROM php:8-cli-alpine as cron
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
RUN apk add --no-cache icu-dev && \
|
|
|
|
|
|
|
|
docker-php-ext-install intl pdo_mysql
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
COPY --from=data /app/ /app
|
|
|
|
|
|
|
|
COPY --from=supercronic /usr/local/bin/supercronic-linux-amd64 /usr/local/bin/supercronic
|
|
|
|
|
|
|
|
COPY docker/crontab /etc/crontab
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ENTRYPOINT ["/usr/local/bin/supercronic"]
|
|
|
|
|
|
|
|
|
|
|
|
# Build the PHP container
|
|
|
|
# Build the PHP container
|
|
|
|
FROM php:8-fpm-alpine
|
|
|
|
FROM php:8-fpm-alpine
|
|
|
|
WORKDIR /var/www
|
|
|
|
WORKDIR /var/www
|
|
|
|