Problem with MariaDB "error while evaluating conditional: not mysql_remote_database"

I’m using trellis to deploy my Bedrock site. When I run the playbook for my staging site I get this error

TASK: [mariadb | Add MariaDB MySQL apt-key] *********************************** 
fatal: [] => error while evaluating conditional: not mysql_remote_database

PLAY RECAP ******************************************************************** 
           to retry, use: --limit @/Users/jonathan/server.retry               : ok=33   changed=1    unreachable=1    failed=0   

I am using an Ubuntu 14.04 AWS instance. The database is a RDS instance. I have the database setup in my wordpress_sites.yml like this:

db_create: false
  db_name: name
  db_user: name
  db_password: 123abc

I’m pretty sure the configs I have in there are correct because I can login to the instance and use the info to connect to the RDS instance.

I’ve been trying to figure this one out for a while, so any help is appreciated.


mysql_remote_database: true

Could you confirm that the line above is not missing or commented out?

I’m only able to replicate the
error while evaluating conditional: not mysql_remote_database
if the variable mysql_remote_database is undefined.

1 Like

Yeah, that did it. Thanks a lot.

Funny story how this happened. We do a lot of Rails development so I had database.yml in my global gitignore. As a result, that file wasn’t being tracked by git.

Part of what was so confusing about this was that everything was working until I moved to a new machine. Turns out the reason for that was the database.yml file never made it up to our repo.

Thanks again for the help :+1:

1 Like