/var/www/html in wordpress-for-tests should not be a volume#1380
/var/www/html in wordpress-for-tests should not be a volume#1380candrews wants to merge 1 commit intoversionpress:masterfrom
Conversation
This directory is used for running tests; it is entirely ephemeral. Also, having it as a volume causes the mkdir and chown in ./dev-env/wordpress-cli-image/Dockerfile to not take effect (since the volume is mounted over /var/www/html), resulting in the tests not being able to write to /var/www/html since its not owned by www-data, resulting in tests failing with this error: ``` Exception: Error executing cmd 'php '/tmp/wp-cli-latest-stable.phar' core download --path='/var/www/html/wptest' --version='4.9' --force --locale='en_US'' from working directory '/var/www/html/wptest': Error: '/var/www/html/wptest/' is not writable by current user. in /opt/versionpress/tests/Automation/WpAutomation.php:621 ```
|
I forgot the details but the idea was that if your tests fail, you can inspect the folder as it's mounted to |
|
You could exec into the docker container and look that way. |
|
Do you know why we don't have a similar problem with other mounts from Don't get me wrong, your reasoning sounds solid to me but I care about the experience of troubleshooting failed tests. |
Travis CI experiencing the exact same error as I do on my Fedora system, so if it's OS dependent, it's probably for all Linux distros.
I do too :) But right now, we have no CI test running and tests are failing. Do you have other thoughts as to how we can solve this problem? It looks like you worked on a closely related issue in 87769bf |
|
Yes, I was quite familiar with many of the details a year ago, more than I would have liked :) I would have to research it again though, which I'm happy to do after I return from holiday later this week. |
|
Superseded by #1388 |
This directory is used for running tests; it is entirely ephemeral.
Also, having it as a volume causes the mkdir and chown in
./dev-env/wordpress-cli-image/Dockerfile
to not take effect (since the volume is mounted over
/var/www/html), resulting in the tests not being able to
write to /var/www/html since its not owned by www-data,
resulting in tests failing with this error:
Resolves #
Write a paragraph or two about the proposed changes here.