Skip to content

Commit

Permalink
Adding one privilege for user (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
ianuragsingh authored Aug 7, 2023
1 parent de0c2d9 commit 3257759
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lambda/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ def provision_db_and_user(master_secrets_json, secret_json):

# Grant privileges
grant_sql = "GRANT CONNECT ON DATABASE {} TO {};".format(database_name, username)
grant_sql += "GRANT ALL PRIVILEGES ON DATABASE {} TO {};".format(database_name, username)
grant_sql += "GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO {};".format(username)
grant_sql += "GRANT ALL PRIVILEGES ON ALL SEQUENCES IN SCHEMA public TO {};".format(username)
grant_sql += "GRANT ALL PRIVILEGES ON ALL FUNCTIONS IN SCHEMA public TO {};".format(username)
Expand Down

0 comments on commit 3257759

Please sign in to comment.