Cloning an existing site


#1

Hi - A client of mine has asked that I make some content updates and structural html changes to their existing Surreal CMS site. Essentially we are doing an entire site refresh. Is there an option to perform these structural changes offline (i.e. make a copy of their site) and then view these changes for sign-off with the client before pushing them live, without affecting the live site? I’m wondering what the best practices are for handling these types of updates? The documentation provides an overview on setting up your first site, but I didn’t see the recommended process for modifying an existing site including changes to css, html, and js files. Any information and/or recommendations you can provide would be very much appreciated.

Thanks!
Jeff


#2

You can use the lockdown feature (Sites > Edit Site) to prevent the client from making changes while you work offline.

In this case I’d recommend using an FTP client to download everything, make your changes, then upload it all back to the server. If you’ve added or removed files, you’ll want to add/remove them in the CMS too.

Note that changing content regions on a page may affect the ability to open drafts and revisions.

Surreal doesn’t care about assets, only page content. In other words, updating your scripts and styles is totally fine — you don’t need to do anything else in the CMS :slight_smile:


#3

Thanks Cory, makes sense!

Since my client wants to iterate together and see the changes in real-time, would it make sense to spin up a new domain and create a new “test” site and then upload copies of the files to this new site?


#4

I would suggest creating a subdomain on your clients domain and call it something like staging.example.com. You can password protect it using basic HTTP authentication which is called directory privacy in cPanel and Surreal CMS will still work if you follow the documentation for white listing the IP address. Subdomains are considered sites so it will use one of your sites in your plan.

If you don’t need to the client to edit the site while you are making changes, it’s probably best to just setup a subdomain and send the details to the client.


#5

I agree with @jeremy on this. A staging domain is usually the best choice. I don’t recommend a subfolder (e.g. example.com/staging) as this can create anomalies with relative links.

Here’s the docs for HTTP Authentication, but if the content isn’t super sensitive you can just use staging.example.com or even something random to prevent accidental views.


#6

Thanks Jeremy, really appreciate it!


#7

Thanks again Cory. I’ll plan on using a staging domain.

Best,
Jeff


#8

No worries. :slight_smile: