Bertrand_Bellenot sought guidance on installing the Docker version of Discourse with a remote PostgreSQL server, specifically one where he lacks superuser permissions Bertrand_Bellenot. Initially, codinghorror expressed doubt that installation was possible without superuser access. However, mpalmer clarified that superuser rights are only required to create the database and role; once those are established by IT, a regular user can complete the setup. mpalmer successfully tested this approach and subsequently published a detailed how-to guide this new, shiny howtompalmer. Bertrand_Bellenot confirmed the solution worked Bertrand_Bellenot. Later, he asked if specific environment variables in web.template.yml needed manual modification to point to the remote instance Bertrand_Bellenot. sam explained that configurations in app.yml override the templates, making such manual edits unnecessary. Bertrand_Bellenot concluded the discussion by confirming a successful migration from phpBB to Discourse Bertrand_Bellenot.
We are migrating our phpbb3 forum to discourse (yeah!)
So I’m trying to install (configure) a standard discourse (docker version) with a remote postgresql server (centrally provided by IT, for which I don’t have superuser permission)
Is there a simple explanation (or a concrete example) how to do it?
Thanks in advance!
Hmm, I dunno… the only thing you should need superuser for is to create the DB and role; from there, the regular user can do everything. So if Central IT (all praise the glorious Leader!) do those bits, and the config in app.yml is setup with the correct creds, surely it’d work OK?
/me gives it a go
OK, that worked well enough (for the most part). I’ll write up a howto topic and link it from here, since there are a few steps to making it work right.
Do we have to modify the web.template.yml file?
In particular this part:
env:
# You can have redis on a different box
RAILS_ENV: 'production'
UNICORN_WORKERS: 3
UNICORN_SIDEKIQS: 1
# this gives us very good cache coverage, 96 -> 99
# in practice it is 1-2% perf improvement
RUBY_GLOBAL_METHOD_CACHE_SIZE: 131072
# stop heap doubling in size so aggressively, this conserves memory
RUBY_GC_HEAP_GROWTH_MAX_SLOTS: 40000
RUBY_GC_HEAP_INIT_SLOTS: 400000
RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR: 1.5
DISCOURSE_DB_SOCKET: /var/run/postgresql
DISCOURSE_DB_HOST:
DISCOURSE_DB_PORT:
Shouldn’t this also point to our remote postgresql instance?
(same question for any other configuration file…)