Skip to content

Commit 5d51ecc

Browse files
committed
test
1 parent 974fa1f commit 5d51ecc

File tree

1 file changed

+9
-2
lines changed
  • ansible/files/admin_api_scripts/pg_upgrade_scripts

1 file changed

+9
-2
lines changed

ansible/files/admin_api_scripts/pg_upgrade_scripts/initiate.sh

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -309,8 +309,15 @@ function initiate_upgrade {
309309
echo "7. Disabling extensions and generating post-upgrade script"
310310
handle_extensions
311311

312-
echo "8. Granting SUPERUSER to postgres user"
313-
run_sql -c "ALTER USER postgres WITH SUPERUSER;"
312+
echo "8. TODO"
313+
# run_sql -c "ALTER USER postgres WITH SUPERUSER;"
314+
run_sql <<-EOSQL
315+
begin;
316+
alter role postgres rename to supabase_admin_;
317+
alter role supabase_admin rename to postgres;
318+
alter role supabase_admin_ rename to supabase_admin;
319+
commit;
320+
EOSQL
314321

315322
if [ -z "$IS_NIX_UPGRADE" ]; then
316323
if [ -d "/usr/share/postgresql/${PGVERSION}" ]; then

0 commit comments

Comments
 (0)