From 2f558127b74ab3519b8254bcb00a80f23518e417 Mon Sep 17 00:00:00 2001 From: Tobias Macey Date: Wed, 8 Mar 2023 14:08:36 -0500 Subject: [PATCH] fix: Remove invalid grant syntax in readonly postgres roles --- src/ol_infrastructure/lib/vault.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ol_infrastructure/lib/vault.py b/src/ol_infrastructure/lib/vault.py index d390b429c..1a5da157a 100644 --- a/src/ol_infrastructure/lib/vault.py +++ b/src/ol_infrastructure/lib/vault.py @@ -80,9 +80,9 @@ GRANT SELECT ON ALL SEQUENCES IN SCHEMA public TO "{{name}}"; SET ROLE "{{name}}"; ALTER DEFAULT PRIVILEGES FOR USER "{{name}}" IN SCHEMA public GRANT SELECT - ON ALL TABLES TO "{{name}}"; + ON TABLES TO "{{name}}"; ALTER DEFAULT PRIVILEGES FOR USER "{{name}}" IN SCHEMA public GRANT SELECT - ON ALL SEQUENCES TO "{{name}}"; + ON SEQUENCES TO "{{name}}"; RESET ROLE;""" ), "revoke": Template(