# Ability to "sync" post content between instances without overwriting settings/users

**URL:** https://meta.discourse.org/t/ability-to-sync-post-content-between-instances-without-overwriting-settings-users/23677
**Category:** Feature
**Created:** [05.Январь.2015 10:49:26 UTC](https://meta.discourse.org/t/ability-to-sync-post-content-between-instances-without-overwriting-settings-users/23677 "2015-01-05T10:49:26Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![kalleth](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/kalleth/32/102787_2.png) [@kalleth](https://meta.discourse.org/u/kalleth)
#### Post date: [05.Январь.2015 10:49:26 UTC](https://meta.discourse.org/t/ability-to-sync-post-content-between-instances-without-overwriting-settings-users/23677/1 "2015-01-05T10:49:26Z")

</div>

Hi there,

Not sure this is `support` although it could be – here’s my use case:

For my clients’ discourse installation I have two environments; staging and production. I have a synchronisation script for the website which syncs data from production to staging each night to keep staging as close to production as possible.

I would like to do the same for discourse, but as the forums are accessible from different hostnames with different admin settings I would only like to sync the post information (and users which aren’t already present in the database, **but anonymising their user account** (i.e. overwriting email/real name/etc fields on the sync so there’s no PII in the staging database – i don’t want to accidentally email real people from staging!)

Is this possible right now? The import/export looks to be a bit full featured for me – i.e. it’ll nuke and overwrite everything. Am I going to have to write a rake task on each and my own importer layer? ☹

---

<div class="post-metadata">

### Author: ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)
#### Post date: [05.Январь.2015 13:53:27 UTC](https://meta.discourse.org/t/ability-to-sync-post-content-between-instances-without-overwriting-settings-users/23677/2 "2015-01-05T13:53:27Z")

</div>

You could setup [mailcatcher](http://mailcatcher.me/) on staging to address the accidentally emailing people issue.

I believe the only supported way currently to sync data is to use the import/export tool.

If you wanted something to just sync post data and new users you will probably need to write your own sync functionality using the [discourse\_api](https://github.com/discourse/discourse_api). Using the api you should be able to get all the new posts and users, but I don’t think there is a good way to bulk insert or modify the dates on insert to match production using the api.

You could also find the right tables in postgres and export and import those directly.

---

<div class="post-metadata">

### Author: ![chapoi](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chapoi/32/537252_2.png) [@chapoi](https://meta.discourse.org/u/chapoi)
#### Post date: [04.Декабрь.2025 11:33:27 UTC](https://meta.discourse.org/t/ability-to-sync-post-content-between-instances-without-overwriting-settings-users/23677/3 "2025-12-04T11:33:27Z")

</div>


