From 922a4acdc5c8198cf7fbaad1100a5ec0a33f7cfb Mon Sep 17 00:00:00 2001 From: Tim Abbott Date: Sat, 30 Jul 2016 20:11:03 -0700 Subject: [PATCH] puppet: Add zulip.conf setting for listen_addresses tuning. --- puppet/zulip/manifests/postgres_appdb_tuned.pp | 1 + .../templates/postgresql/9.5/postgresql.conf.template.erb | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/puppet/zulip/manifests/postgres_appdb_tuned.pp b/puppet/zulip/manifests/postgres_appdb_tuned.pp index f5e670e654..2b042df152 100644 --- a/puppet/zulip/manifests/postgres_appdb_tuned.pp +++ b/puppet/zulip/manifests/postgres_appdb_tuned.pp @@ -71,6 +71,7 @@ vm.dirty_background_ratio = 5 $random_page_cost = zulipconf("postgresql", "random_page_cost", undef) $effective_io_concurrency = zulipconf("postgresql", "effective_io_concurrency", undef) $replication = zulipconf("postgresql", "replication", undef) + $listen_addresses = zulipconf("postgresql", "listen_addresses", undef) file { "/etc/postgresql/${zulip::base::postgres_version}/main/postgresql.conf": require => Package["postgresql-${zulip::base::postgres_version}"], diff --git a/puppet/zulip/templates/postgresql/9.5/postgresql.conf.template.erb b/puppet/zulip/templates/postgresql/9.5/postgresql.conf.template.erb index 5827af041a..6f97eab9ba 100644 --- a/puppet/zulip/templates/postgresql/9.5/postgresql.conf.template.erb +++ b/puppet/zulip/templates/postgresql/9.5/postgresql.conf.template.erb @@ -661,6 +661,10 @@ random_page_cost = <%= scope["zulip::postgres_appdb_tuned::random_page_cost"] %> effective_io_concurrency = <%= scope["zulip::postgres_appdb_tuned::effective_io_concurrency"] %> <% end -%> +<% if scope["zulip::postgres_appdb_tuned::listen_addresses"] -%> +listen_addresses = <%= scope["zulip::postgres_appdb_tuned::listen_addresses"] %> +<% end -%> + <% if scope["zulip::postgres_appdb_tuned::replication"] -%> # Master replication settings (ignored on standby) wal_level = hot_standby