Automate configuration of CSS/HTML and Text Content data


(Christopher Kampmeier) #1

We’ve been successful in automating configuration of Site Settings during creation of a new Discourse site via the standard Docker-based distribution using the exec technique within app.yml:

  - exec: rails r "SiteSetting.display_name_on_posts='true'"

We’d like to extend it further by automating configuration of the Customize -> CSS/HTML and Text Content data.

Is there a means to incorporate configuration of these areas into the app.yml file so that they can be set during ./launcher bootstrap?


(Kane York) #2

Hmm, you should probably move those out of the run: section and into a after_bundle_exec: section, so it runs right after migrations, if you want to go farther with automation.

If you start using multisite, you’ll need one of those for each database with RAILS_DB=foo at the front.