0

I recently successfully deployed the initial version of a WordPress project under development to Google App Engine using the Google App Engine Launcher. It works great. I make edits locally. Hit a button that says Deploy. Done.

However, on the next deployment I realized that everything that was done inside the WordPress dashboard locally does not make it up to the cloud deployment. The plugin files, style.css, and other files I edited upload just fine. Just not the database I'm guessing?

So using this workflow I have to do every WordPress dashboard change twice - once locally and again on the cloud. Can someone please tell me if I am missing a step here? This is my first time working with Google App Engine. Thanks!

1 Answer 1

1

If you used the Quick Start WordPress for Google App Engine project, it's actually configured to use a different database locally than it is in production. Locally it will connect to a local MySQL instance on 127.0.0.1, and in production it will connect to a remote CloudSQL instance. You can see the relevant config in wp-config.php.

Deployment does not sync changes from your local MySQL to your production database. This could be bad for a few reasons (not the least of which would be overwriting your production data with local test data). The local MySQL database is intended to be isolated from production for testing purposes.

The recommended workflow to deploy first, then only use the remote WordPress dashboard to make changes in production. If you need to do some local development with a snapshot of production data, you can export from CloudSQL to your local MySQL instance. Taking that a step further, you could even configure your local MySQL database as a one-way asynchronous replica of your CloudSQL instance.

In general you should never be syncing or exporting your database the other way (from local to production), unless you are doing some kind of disaster recovery.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.