Backup solo delle impostazioni del sito

I would like to know the possibility of backing up Only Site Settings, just as opposite of what was asked here

The purpose is to replicate forums for different clients. If I can replicate settings, its easy to proceed with different categories, topics & users.

Please advise.

PS: I couldn’t understand by reading this

I think @zogstrip suggested entering the forum database you want to replicate (via SSH), clone the site_settings table into that database and replace that particular table in each new site you’re going to create.

I believe @techapj has expressed interest in this feature but we do not have it yet.

Alright.

So, I need to install Discourse as usual and take this step to replicate the settings. Will the instance version different make any conflicts here?

If we have to get the forum logo to new one, we will have to re-upload this, I suppose. Am I right?

Save https://yoursite/admin/site_settings.json. Use GitHub - pfaffman/discourse-settings-uploader: Install a Discourse settings JSON file to a site to upload them.

To install these settings to another site

Do this:

./discourse-settings-uploader HOSTURL API_KEY API_USER SETTINGS_FILE

For example:

./discourse-settings-uploader https://discourse.example.com d35989078a system site_settings.json

One caveat: It uploads only settings that are marked as changed. This means that if there’s some setting that’s changed on the site you’ve uploaded that you want to restore to default with the script it won’t work. The solution is to edit the JSON file so that the default value there doesn’t match the value you want to set.

Now what’s needed is a way to easily download all themes and then upload them. Uploading
a set of files shouldn’t be hard to do. Downloading themes by hand could be tedious, so some automated way to get all of them would be nice.

This sounds good. Will try this method next time I create a new forum.

I hope Discourse version difference will not make any issue, however I do update forums on regular basis… :slight_smile:

As long as the setting is available it will be set. Settings that don’t exists can’t get set, but make only that it doesn’t get set. For example, if you have a plugin installed on the system your are copying from its settings exist only if the target system has the plugin as well. When that happens an error is presented for each unavailable setting.

Oh this would be such a life saver feature.

See here: Administrative Bulk Operations

Sarebbe fantastico se aggiungeste un’opzione per esportare/backuppare le impostazioni attuali del sito in un file, per poi permettere a un nuovo forum di importare tale file e replicare le stesse impostazioni. Qualcuno può implementare questa funzione? Sarebbe una caratteristica molto utile nel caso volessi un clone completo dei dati e delle impostazioni del mio sito.

Quali opzioni ho a disposizione se desidero un clone completo del mio forum attuale, inclusi i dati degli utenti, i topic, i post, le immagini, nonché le impostazioni di amministrazione di Discourse e dei plugin come le ho configurate? Qualcuno può aiutarmi, per favore? @pfaffman

Attualmente posso salvare solo i file app.yml e la cartella discourse, che contiene una sottocartella chiamata shared; credo che lì siano conservati tutti i dati del database e i file caricati dagli utenti.

Sono descritte sopra due modalità per farlo.

Crea un nuovo forum. Esegui il backup del tuo forum attuale. Ripristina quel backup sul nuovo forum. Puoi risparmiare alcuni passaggi se entrambi i forum utilizzano lo stesso bucket S3 per i backup.

Grazie per la risposta rapida,

Crea un nuovo forum. Esegui il backup del forum attuale. Ripristina quel backup sul nuovo forum. Puoi risparmiare alcuni passaggi se entrambi i forum utilizzano lo stesso bucket S3 per i backup.

Perché devo eseguire manualmente solo il backup delle impostazioni del sito, se il metodo sopra descritto già esegue il backup di tutte le impostazioni dei plugin e del sito, nonché di immagini, upload, database, post, argomenti, ecc.?

Se seguo questi 3 passaggi, l’esportazione del mio sito mi fornirà un backup completo delle impostazioni del sito e dei plugin, oltre a quelle del database e degli upload di file?

  1. Crea un nuovo forum.
  2. Esegui il backup del forum attuale accedendo alla dashboard dell’interfaccia amministrativa e alla sezione backup (non dalla riga di comando, giusto?)
  3. Ripristina questo nuovo backup ottenuto al passaggio 2 e inseriscilo nel nuovo forum creato al passaggio 1.
  4. Bene, non ho ancora alcun bucket per i backup; il mio forum è semplicemente ospitato su un droplet DO e si trova in una directory del mio server, all’interno della cartella var/discourse/shared. Ma non capisco perché il mio file yml di Discourse si trovi in /www/discourse; non comprendo perché tutti i file di Discourse siano distribuiti in queste due cartelle che risiedono su percorsi diversi.?

Si prega di confermare.