The Repo is superset-client
with the ruby gem named superset
All ruby classes are namespaced under Superset::
Follow this to setup your users API creds
Short version is .. copy the env.sample
to .env
and add edit values where applicable. Opening a console with bin/console
will then auto load the .env
file.
Build, bundle and open a ruby console
docker-compose build
docker-compose run --rm app bundle install
docker-compose run --rm app bin/console
Requires Ruby >= 2.6.0
Bundle install and open a ruby console.
bundle install
bin/console
Add to your Gemfile gem 'superset'
And then execute: bundle install
Or install it yourself as gem install superset
docker-compose run --rm app rspec
# or
docker-compose run --rm app bash # then run 'bundle exec rspec' from the container.
Experiment with the API calls directly by open a pry console using bin/console
.
Superset::Dashboard::List.call
superset_class_list # helper method to list all classes under Superset::
sshelp # aliased for superset_class_list
More examples listed here
One Primary motivation behind this gem was to use the Superset API to duplicate dashboards, charts, datasets across multiple database connections.
Targeted use case was for superset embedded functionality implemented in a application resting on multi tenanted database setup.
See examples in Duplicate Dashboards
With a few configuration changes to an import file, the process can be codified to transfer a dashboard between environments.
See example in Transferring Dashboards across Environments
- Fork it
- Create your feature branch (git checkout -b my-new-feature)
- Commit your changes (git commit -am 'Add some feature')
- Push to the branch (git push origin my-new-feature)
- Create new Pull Request
WIP .. direction is for this gem to be made public
The gem is available as open source under the terms of the MIT License.