zulip/scripts/setup
Alex Vandiver faf71eea41 upgrade-postgresql: Do not remove other supervisor configs.
We previously used `zulip-puppet-apply` with a custom config file,
with an updated PostgreSQL version but more limited set of
`puppet_classes`, to pre-create the basic settings for the new cluster
before running `pg_upgradecluster`.

Unfortunately, the supervisor config uses `purge => true` to remove
all SUPERVISOR configuration files that are not included in the puppet
configuration; this leads to it removing all other supervisor
processes during the upgrade, only to add them back and start them
during the second `zulip-puppet-apply`.

It also leads to `process-fts-updates` not being started after the
upgrade completes; this is the one supervisor config file which was
not removed and re-added, and thus the one that is not re-started due
to having been re-added.  This was not detected in CI because CI added
a `start-server` command which was not in the upgrade documentation.

Set a custom facter fact that prevents the `purge` behaviour of the
supervisor configuration.  We want to preserve that behaviour in
general, and using `zulip-puppet-apply` continues to be the best way
to pre-set-up the PostgreSQL configuration -- but we wish to avoid
that behaviour when we know we are applying a subset of the puppet
classes.

Since supervisor configs are no longer removed and re-added, this
requires an explicit start-server step in the instructions after the
upgrades complete.  This brings the documentation into alignment with
what CI is testing.
2021-08-24 19:00:58 -07:00
..
apt-repos scripts: Use curl -f (--fail). 2021-07-13 16:47:49 -07:00
__init__.py setup: Add missing __init__.py. 2021-07-05 12:20:39 -07:00
compare-settings-to-template python: Remove default "utf8" argument for encode(), decode(). 2021-08-02 15:53:52 -07:00
configure-rabbitmq configure-rabbitmq: Wait for RabbitMQ to start up. 2020-10-15 17:01:00 -07:00
create-db.sql create-db: Default dbuser and dbname to zulip. 2021-05-26 17:19:11 -07:00
create-pgroonga.sql postgres-create-db: Split into non-pgroonga and pgroonga scripts. 2019-07-17 16:18:22 -07:00
flush-memcached memcached: Switch from pylibmc to python-binary-memcached. 2020-08-06 12:51:14 -07:00
generate-self-signed-cert shfmt: Reformat shell scripts with shfmt. 2020-10-15 15:16:00 -07:00
generate_secrets.py settings: Support arbitrary database user and dbname. 2021-05-25 13:46:58 -07:00
initialize-database docs: Add missing space to compound verbs “log in”, “set up”, etc. 2021-04-26 09:31:08 -07:00
inline_email_css.py python: Remove locally dead code. 2021-08-19 01:51:37 -07:00
install install: Use a period at end of root error message. 2021-06-23 08:42:46 -07:00
postgresql-init-db postgresql-init-db: Support arbitrary database user and dbname. 2021-05-25 13:56:04 -07:00
reindex-textual-data reindex-textual-data: Provide a tool to reindex all text indices. 2021-07-19 16:34:23 -07:00
restore-backup python: Reformat with Black, except quotes. 2021-02-12 13:11:19 -08:00
setup-certbot shfmt: Reformat shell scripts with shfmt. 2020-10-15 15:16:00 -07:00
sha256-tarball-to scripts: Use curl -f (--fail). 2021-07-13 16:47:49 -07:00
terminate-psql-sessions terminate-psql-sessions: Rely on the caller to set PGHOST, PGUSER. 2020-06-15 21:37:14 -07:00
upgrade-postgresql upgrade-postgresql: Do not remove other supervisor configs. 2021-08-24 19:00:58 -07:00