woocommerce/tests/e2e/env/docker/wp-cli/Dockerfile

23 lines
643 B
Docker

FROM wordpress:cli-php7.4
USER root
COPY wait-for-it.sh /usr/local/bin/wait-for-it
RUN chown xfs:xfs /usr/local/bin/wait-for-it && \
chmod +x /usr/local/bin/wait-for-it
COPY entrypoint.sh /usr/local/bin/entrypoint.sh
RUN chown xfs:xfs /usr/local/bin/entrypoint.sh && \
chmod +x /usr/local/bin/entrypoint.sh
RUN chown xfs:xfs /home/www-data
COPY initialize.sh /usr/local/bin/initialize.sh
RUN chown xfs:xfs /usr/local/bin/initialize.sh && \
chmod +x /usr/local/bin/initialize.sh
USER xfs
RUN mkdir /home/www-data/.wp-cli && echo "path: /var/www/html" > /home/www-data/.wp-cli/config.yml
USER root
ENTRYPOINT ["entrypoint.sh"]