Hi @cdc43339
It seems that your production site and staging one are suffering an identity crisis. In summary, a Jetpack-connected site is assigned a Blog ID which represents its identity and contains its data (that is synced on our end); what is happening here is that Jetpack is confusing these two sites (production and staging) thinking it’s the same one and that it’s just an URL change.
You can avoid that from happening by using the Staging Mode on the staging site; this is explained on our documentation below:
https://jetpack.com/support/staging-sites/
It’s good to note that it’s best if you are able to prevent the wp-config.php file from being cloned while cloning to production or staging; your host may be able to guide and provide more information about whether that’s possible or not on their end.
Best,
I was able to place the staging site into staging mode, but that doesn’t solve the problem with production. How do I turn off safe mode for prod, without losing any site stats? If I click “Fix Jetpack’s Connection,” I am given “Migrate Stats and Subscribers” (but it says migrate from <stagingURL> to <prodURL>) or “Start Fresh and Create New Connection.” I’m guessing I want “Migrate?” I need to keep the stats and subscribers, and to know that I’m not destroying anything by proceeding.
Hi @cdc43339
There are currently two ways to do staging sites on WPEngine, but only one currently is able to work with Jetpack.
We’ve got an open issue here where we’re looking into this:
https://github.com/Automattic/jetpack/issues/21504
You can also see WPEngine’s documentation on this here:
https://wpengine.com/support/staging-environments-1-click-staging-different/
When you use staging are you using the Staging/Development Environments or the Legacy 1-Click Staging version?
Staging / Dev environments, not the legacy staging setup. Direction on how to proceed without losing stats?
Hi @cdc43339
Staging/Development Environments is currently not supported by Jetpack, so it makes sense why the issue is happening when you are pushing from Production to Staging, and there isn’t a specific way to avoid that as it will happen every time you push from Production to Staging.
At this point, I’d suggest if you reached out to WPEngine and see if they’re able to exclude the wp-config.php file from being altered when you push from Production to Staging; otherwise, you could follow along with the progress of the Github issue that my colleague had mentioned below:
https://github.com/Automattic/jetpack/issues/21504
Our developers are looking into that, but there’s isn’t an ETA for that. I’ve also added your thread there.
Best,
@muffinpeace thanks for the link. That looks like it could be helpful going forward, but I’m still looking for a response to the core question:
I was able to place the staging site into staging mode, but that doesn’t solve the problem with production. How do I turn off safe mode for prod, without losing any site stats? If I click “Fix Jetpack’s Connection,” I am given “Migrate Stats and Subscribers” (but it says migrate from <stagingURL> to <prodURL>) or “Start Fresh and Create New Connection.” I’m guessing I want “Migrate?” I need to keep the stats and subscribers, and to know that I’m not destroying anything by proceeding.