How is nixos_site_settings.json file used in NixOS configuration for Discourse?

Hi Everybody,

I’m trying to Nixify my Discourse currently running inside Docker and I’m looking into Discourse NixOS module and derivation.

One thing that I can’t figure out is how is nixos_site_settings.json

file used/applied. I’m looking at the actual shell script that is in ExecStartPre of discourse.service:

/nix/store/9rxqymz0cb33lix6l2vwhhy0rkjfv4dv-jq-1.7.1-bin/bin/jq >'/run/discourse/config/nixos_site_settings.json' '.' <<'EOF'
{"basic":{"allow_user_locale":true},"email":{"manual_polling_enabled":true,"reply_by_email_address":"%{reply_key}","reply_by_email_enabled":true},"required":{"contact_email":"","notification_email":"","site_description":" Discourse","title":" Discourse"},"security":{"force_https":false}}

and I don’t see that file to be used by NixOS or by Discourse. I looked into my Docker Discourse and I didn’t find any *.json files like this and I searched for nixos_site_settings.json in Nixpkgs and I didn’t find anything interesting

Is nixos_site_settings.json unused or is it somehow used and I don’t understand it?

Thank you.