3

A client has asked us if its possible to preview content changes on a Staging site and then when it's ready to be published, it would appear on the Production site without having to re-key all of the content and asset uploads/changes.

I wondered if anyone has looked into this kind of Content staging with ExpressionEngine before?

I know that some other CMS' have something similar, but i'm not aware of anything out of the box with EE.

Typically, we run the usual Local/Dev, Staging and Production environments and we regularly migrate a copy of the Production database over to Local and Staging so that they're in sync which helps when we're working on new features.

Our client also tests out content changes on the staging site, for example when they have a new season campaign.

I know that there are also some workflow add-ons that would have preview versions of content on the Production site as well, so this might be the route to take.

Thanks.

1
2

I'll elaborate more on my comment to answer the poster more fully...

There isn't a reliable, solid mechanism (especially automated) that I've come across that can safely migrate content forwards onto a live site - especially if you have living data (membership, commenting, forums, etc). If considering this, also remember environment configs and entry hit tracking also.

Here's a great Stack Exchange post that summarises the publishing flow of templates & files versus data.

There is an add-on called Site Manager referenced in the above post which was only in Alpha state and doubtful it will be compatible with the latest v2.x as it's 4 years old.

Hence the suggestion of keeping it simple and using a publishing module for a Production server, two I've used in the past:

Better Workflow (highly recommended)

Publisher

You could consider a content freeze on your live site, during the building and testing of a campaign in Dev or Staging (which have fresh copies of your live site), then export the finished campaign entries via SQL (and only the entries modified) and import into the live site database. You'll need a content freeze on live to ensure that the entry IDs don't get muddled up and remain unique.

Alternatively you could do as above without the content freeze and use DataGrab to import your entries (maybe exported via template code as a CSV) and import the entries with freshly generated Entry IDs. Issues may arise with certain fieldtypes and compatibility.

But that still doesn't allow for images or resources added via entries...!

0

I second Peter's suggestion of Better Workflow. https://devot-ee.com/add-ons/better-workflow

0

Rename the Staging site to Production when ready.

Change DNS/whatever on Staging to Prod. There I said it. Grab some pitchforks.

Seriously though, I develop on a cPanel/WHM cluster and have a specific machine for Dev, Staging and Production.

When ready, rename the cPanel hosting account from "beta.xxx.com" to "xxx.com" as well as the zone records for the production domain. I usually do an account move to a production machine in the cluster first.

I know this workflow is cPanel specific and kinda nasty but the principles are adaptable.

Saves moving data and replicating environments.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.