woocommerce/plugins/woocommerce-blocks/bin/docker/wp-cli/Dockerfile

19 lines
500 B
Docker
Raw Normal View History

Fix wp-cli container permissions issues for e2e docker test environment (https://github.com/woocommerce/woocommerce-blocks/pull/1716) * add docker files * get tests to work * remove irrelevant files * change userAgent to chrome * add woocommerce as a dep * add jest to eslint * remove eslintignore for tests * undo travis chages till another PR * remove local utils and call them directly from woocommerce * update deps * add setup files to run tests * export default wp link * wait for select before selecting * remove travis db * ignore e2e tests in unit testing * add tests * add docker commands * always run composer * Make it possible to import directly from '@woocommerce/e2e-tests/utils' * remove installing woocommerce via composer. * add more docker npm scripts * add custom docker config for wp-cli * add changes to docker-composer.yml Includes reading environment variables from `.env` * revert customizations to .travis.yml * move main docker file for the wordpress container to bin * fix travis config * rename wp install for travis builds back to original name * use a version of docker-compose that travis supports * add minor change to try and force travis test run * fix incorrect command * copy composer lock from master * only run phpcs on /src directory * give time for host to spin up for e2e tests * increase sleep for waiting on container * make sure plugin is built before running tests * sigh fix improper command usage Co-authored-by: Seghir Nadir <nadir.seghir@gmail.com> Co-authored-by: Albert Juhé Lluveras <aljullu@gmail.com>
2020-02-11 16:13:20 +00:00
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
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"]