Closed dalepgrant closed 4 months ago
Hi, I cannot reproduce this issue in a testing environment. Can you tell us more about your configuration?
Here are the steps I took to reproduce:
site
directory, call it second_site
wordpress_sites.yml
and vault.yml
adding a second site to each, changing the key, url, and subtree path as necessaryThe change was NOT reflected on the second site. This issue was not reproduced.
So can you tell us more?
Thanks for checking @MWDelaney 🙏 I've been meaning to come back with more info as I know I wrote this report super quick.
I didn't realise but I can actually replicate this in my local. I will try to get a repeatable demo up for you to check, but all I have to do to trigger this is add the change from #714 into two sites and it goes haywire.
I'll come back to add more, but here's some screenshots to show what I'm seeing and the steps I took:
I've narrowed this down to usage with Redis, can reproduce consistently with a test setup.
Scratch that. In prepping the repo for someone to look at and reproduce, I've found the error of my ways. 🤦♂️
We were using Config::define('WP_CACHE_KEY_SALT', getenv('DB_NAME'));
to avoid conflicts with dbs when using Redis. The getenv()
turned out to be the issue. Change to env()
and voila, no more issues. Should have read the issue notes more clearly, it does say about getenv()
(and putenv()
).
I'll leave the repo up, maybe it'll help someone else. Thanks for looking at this 🙏
Version
714
What did you expect to happen?
Retain the ability to host multiple sites on one server.
What actually happens?
The changes introduced in #714 cause havoc, the best way I can describe it is that domain2.com starts trying to use domain1.com's database.
Steps to reproduce
Deploy two Bedrock sites on the same server at different URLs Change the settings in WP Admin of both sites (anything, active themes, active plugins, Site name, whatever) One site will take the values of the other Remove the changes from #714 Note that both sites gain their independence again.
System info
Ubuntu 22.04 provisioned with Trellis (https://github.com/roots/trellis/commit/b791d54e8f6c9dcc5a909a51d9368136cf04f455)
Log output
No response
Please confirm this isn't a support request.
Yes