zulip/puppet/zulip_ops/manifests
Anders Kaseorg 9f7c0b7e65 postgres_master.pp: Fix wacky su command line.
The construction `su postgres -c -- bash -c 'psql …'` didn’t behave the
way it reads, and only worked by accident:

1. `-c --` sets the command to `--`.
2. `bash` sets the first argument to `bash`.
3. `-c 'psql …'` replaces the command with `psql …`.

Thus, `su` ended up executing `<shell> -c 'psql …' bash`, where
`<shell>` is the `postgres` user’s login shell, usually also `bash`,
which then executed 'psql …' and ignored the extra `bash`.

Unconfuse this construction.

Note from tabbott: The old code didn't even work by accident, it was
just broken.  The right fix is to move the quoting around properly.

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2019-04-12 17:27:23 -07:00
..
apache.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
app_frontend.pp puppet: Disable log2zulip cron job. 2019-01-05 10:56:44 -08:00
apt_repository_debathena.pp puppet/zulip_ops: Replace apt::source with setup-apt-repo-debathena. 2018-12-11 13:02:56 -08:00
base.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
git.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
init.pp puppet: Rename zulip_internal to zulip_ops. 2016-10-16 19:23:27 -07:00
loadbalancer.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
munin.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
nagios.pp puppet: Fix puppet-lint warnings in various manifests. 2018-08-28 13:46:31 -07:00
postgres_appdb.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
postgres_common.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
postgres_master.pp postgres_master.pp: Fix wacky su command line. 2019-04-12 17:27:23 -07:00
postgres_slave.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
prod_app_frontend.pp puppet: Don't run calculate-first-visible-message-id on most systems. 2018-10-30 11:40:24 -07:00
redis.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
staging_app_frontend.pp puppet-lint: Enforce double_quoted_strings check. 2018-08-13 12:31:19 -07:00
zmirror.pp puppet/zulip_ops: Replace apt::source with setup-apt-repo-debathena. 2018-12-11 13:02:56 -08:00
zmirror_personals.pp puppet/zulip_ops: Replace apt::source with setup-apt-repo-debathena. 2018-12-11 13:02:56 -08:00