This is a MVP script for loading bulk users to Superset via the API. It expects a csv file, see /src/template.csv for a sample.
- It uses the permissions of the default dashboard viewer role to create custom roles from the csv
- It creates users and assigns them roles (1:1 mapping). The tables to be accessed are defined in the .env file
- It create row-level-security entries to ensure role based access to the dashboards
- Populate your csv file, refer to the
./src/template.csvfor a sample - Define your environment variables - make a copy of
.env.templateand rename to.env - Install dependencies: run
npm i - Build: run
npm run build - Start: run
npm run start
Starts the app in dev mode using nodemon and ts-node for hot reloading.
Starts the app in prod mode, first building the app with npm run build, and then runs the compiled JavaScript at build/index.js.
Builds the app to /build.
Runs the jest tests once.
Run the jest tests in watch mode.
Formats your code.
Formats your code in watch mode.
- This script is in active development. Errors are expected.