Skip to content

Conversation

LiamKarlMitchell
Copy link

wpcli could not seem to connect as the environment variables were not set.

E.g. I had this in my ~/.bash_profile

alias wp="docker-compose run --rm wpcli"

Then tried to run
wp post list

Which previously showed
Error: Error establishing a database connection.

Confirmed by echoing the constants defined in the wp-config.php

Make wpcli able to connect to db when ran.
E.g.
```alias wp="docker-compose run --rm wpcli"```
```wp post list```
As per The0mikkel's instruction, adding " around the title parameter in the wpcli/Makefile fixes a problem where it would not run on Debian.
kassambara#2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant