ARG  VERSION="latest"
FROM "registry.cabillot.eu/www/phpapache:${VERSION}"
LABEL maintainer="Julien Cabillot <dockerimages@cabillot.eu>"

# Nécessaire pour le git clone plus loin
WORKDIR "/var/www"

RUN apt-get -qq update && \
    apt-get -qq --yes install libpng12-dev git && \
    docker-php-ext-install gd && \
    rmdir "/var/www/html" && \
    git clone "https://github.com/blueimp/jQuery-File-Upload.git" "/var/www/html" && \
    apt-get -qq --yes remove --purge libpng12-dev && \
    apt-get -qq --yes autoremove --purge && \
    apt-get -qq --yes clean all && \
    rm -rf "/usr/share/doc/"* \
           "/var/cache/"* \
           "/var/lib/apt/lists/"* \
           "/usr/src/"* \
           "/var/cache/"* \
       "/var/log/"{apt/*,dpkg.log} \
           "/var/www/html" \
           "/tmp/"*

