datacube.drivers.common_psql.grant_role#
- datacube.drivers.common_psql.grant_role(conn, role, users)[source]#
Grant a UserRole to a user(s).
Attempts to revoke any existing memberships of more privileged roles from the user first.
- Parameters:
conn (
Connection) – An SQLAlchemy connection objectrole (
UserRoleBase) – The role to grant
- Return type:
- Returns:
True if the role was granted successfully.