Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
upgrade-postgresql: Only touch pgroonga_setup.sql.applied if required.
Alex Vandiver2dc5c6c50ed3
diff --git a/scripts/setup/upgrade-postgresql b/scripts/setup/upgrade-postgresqlindex c0c17666148..a441b967b6f 100755--- a/scripts/setup/upgrade-postgresql+++ b/scripts/setup/upgrade-postgresql@@ -76,7 +76,12 @@ fiZULIP_CONF="${TEMP_CONF_DIR}/zulip.conf"crudini --set "$ZULIP_CONF" postgresql version "$UPGRADE_TO"crudini --set "$ZULIP_CONF" machine puppet_classes zulip::profile::base,zulip::postgresql_base- touch "/usr/share/postgresql/$UPGRADE_TO/pgroonga_setup.sql.applied"++ if [ -f "/usr/share/postgresql/$UPGRADE_FROM/pgroonga_setup.sql.applied" ]; then+ # This file is intentionally blank, to trigger always running+ # `ALTER EXTENSION pgroonga UPDATE` and not `CREATE EXTENSION pgroonga`.+ touch "/usr/share/postgresql/$UPGRADE_TO/pgroonga_setup.sql.applied"+ fiFACTER_LEAVE_SUPERVISOR=true "$ZULIP_PATH"/scripts/zulip-puppet-apply -f --config "$ZULIP_CONF"rm -rf "$TEMP_CONF_DIR"