tree: 3ea817881188a711e76771c132742a1dbf437f36 [path history] [tgz]
  1. docker-entrypoint-initdb.d/
  2. entrypoints/
  3. nginx/
  4. pythonpath_dev/
  5. superset-websocket/
  6. .env
  7. apt-install.sh
  8. docker-bootstrap.sh
  9. docker-frontend.sh
  10. docker-healthcheck.sh
  11. docker-init.sh
  12. docker-pytest-entrypoint.sh
  13. frontend-mem-nag.sh
  14. pip-install.sh
  15. README.md
  16. tag_latest_release.sh
docker/README.md

Getting Started with Superset using Docker

Docker is an easy way to get started with Superset.

Prerequisites

  1. Docker
  2. Docker Compose

Configuration

The /app/pythonpath folder is mounted from ./docker/pythonpath_dev which contains a base configuration ./docker/pythonpath_dev/superset_config.py intended for use with local development.

Local overrides

Environment Variables

To override environment variables locally, create a ./docker/.env-local file (git-ignored). This file will be loaded after .env and can override any settings.

Python Configuration

In order to override configuration settings locally, simply make a copy of ./docker/pythonpath_dev/superset_config_local.example into ./docker/pythonpath_dev/superset_config_docker.py (git-ignored) and fill in your overrides.

WebSocket Configuration

To customize the WebSocket server configuration, create ./docker/superset-websocket/config.json (git-ignored) based on ./docker/superset-websocket/config.example.json.

Then update the superset-websocket.volumes config to mount it.

Docker Compose Overrides

For advanced Docker Compose customization, create a docker-compose-override.yml file (git-ignored) to override or extend services without modifying the main compose file.

Local packages

If you want to add Python packages in order to test things like databases locally, you can simply add a local requirements.txt (./docker/requirements-local.txt) and rebuild your Docker stack.

Steps:

  1. Create ./docker/requirements-local.txt
  2. Add your new packages
  3. Rebuild docker compose
    1. docker compose down -v
    2. docker compose up

Initializing Database

The database will initialize itself upon startup via the init container (superset-init). This may take a minute.

Normal Operation

To run the container, simply run: docker compose up

After waiting several minutes for Superset initialization to finish, you can open a browser and view http://localhost:8088 to start your journey.

Developing

While running, the container server will reload on modification of the Superset Python and JavaScript source code. Don't forget to reload the page to take the new frontend into account though.

Production

It is possible to run Superset in non-development mode by using docker-compose-non-dev.yml. This file excludes the volumes needed for development.

Resource Constraints

If you are attempting to build on macOS and it exits with 137 you need to increase your Docker resources. See instructions here (search for memory)