FROM php:7.4-alpine

RUN apk update
RUN apk add git

RUN mkdir -p /usr/local && \
    cd /usr/local && git clone https://github.com/pk-fr/yakpro-po.git && \
    cd yakpro-po && git clone https://github.com/nikic/PHP-Parser.git --branch 4.x && \
    chmod a+x yakpro-po.php && \
    ln -s /usr/local/yakpro-po/yakpro-po.php /usr/local/bin/yakpro-po

COPY ./docker/config.php /usr/local/yakpro-po

COPY ./module/oc_telegram_shop/upload/oc_telegram_shop /app
COPY ./scripts /scripts
