42_Inception/srcs/wordpress/Dockerfile

23 lines
645 B
Docker

FROM alpine:3.17
RUN apk update
RUN apk add php php-phar php-fpm php-mysqli php-iconv mysql-client php-json php-curl php-dom php-exif php-fileinfo php-mbstring php-openssl php-xml php-zip php-tokenizer php-session
RUN mkdir -p /var/www/
WORKDIR /var/www/
RUN wget https://wordpress.org/latest.tar.gz
RUN tar -xzf latest.tar.gz
RUN rm latest.tar.gz
RUN sed -i "s/^listen.*/listen = 9000/" /etc/php81/php-fpm.d/www.conf
WORKDIR wordpress
RUN wget https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
RUN chmod +x wp-cli.phar
RUN mv wp-cli.phar /usr/local/bin/wp
COPY entrypoint.sh /
ENTRYPOINT ["sh", "/entrypoint.sh"]