1
0
Fork 0
mirror of https://codeberg.org/demostf/api.git synced 2026-06-03 09:54:17 +02:00
api/Dockerfile
Robin Appelman 44c4945530 update parser
fixed demos with malformed utf8 in chat messages
2019-08-22 21:38:45 +02:00

23 lines
914 B
Docker

FROM registry.gitlab.com/rust_musl_docker/image:stable-latest AS build
ENV PARSER_VERSION 6b0442741ee8365e2df04e653d4ce7068351a332
WORKDIR /root/build
RUN git clone https://github.com/demostf/parser
WORKDIR /root/build/parser
RUN git checkout $PARSER_VERSION
RUN cargo build --release --target=x86_64-unknown-linux-musl
FROM icewind1991/php-alpine-apcu
COPY --from=build /root/build/parser/target/x86_64-unknown-linux-musl/release/parse_demo /app/parse_demo
COPY composer.json /app
COPY src /app/src
ENV PARSER_PATH /app/parse_demo
RUN wget https://getcomposer.org/composer.phar \
&& php composer.phar --working-dir=/app install --no-dev --no-interaction --ignore-platform-reqs \
&& rm composer.phar
RUN echo "clear_env = no" >> /usr/local/etc/php/php-fpm.conf \
&& echo "post_max_size = 150M" >> /usr/local/etc/php/php.ini \
&& echo "upload_max_filesize = 150M" >> /usr/local/etc/php/php.ini