Skip to content
This repository has been archived by the owner on Mar 3, 2021. It is now read-only.

emcasa/rum

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Redshift User Management

Tool to help managing users, groups and schemas on AWS Redshift. It creates random passwords to new users and send them by email alongside the database credentials.

Installing the project locally

  1. Clone the repository and create a new virtual environment:
git clone https://github.com/emcasa/rum.git
cd rum
python3 -m virtualenv env
source env/bin/activate
  1. Install all dependencies by running:
pip install -r requirements.txt

local.env. Then export the env vars using:

cp template_local.env local.env
set -a source local.env set +a
  1. Run the code in your preferred IDE.

Usage Examples

To create a new user:

from app import RedshiftUserManagement
 
rum = RedshiftUserManagement('<username>', '<[email protected]>')
rum.add_user()
>>> User <username> created with password "randompassword" (without quotes).

To remove a user:

rum.remove_user()
>>> User <username> dropped.

To create a new schema with ownership to :

from app import RedshiftSchemaManagement

rsm = RedshiftSchemaManagement('<schema_name>')
create_read_only_schema('<username>')
>>> Schema <schema_name> created.

About

Redshift User Management Tool

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages