In this post I will set up an Ubuntu 20.04.1 LTS VM in order to install Docker and Compose to deploy a superset container image.

I will use the following documentation to set up the VM. This is already well documented but I want to bring all documentation in one post together.

Installing Superset Locally Using Docker Compose
https://superset.apache.org/docs/installation/installing-superset-using-docker-compose



Install the Ubuntu 20.04.1 LTS VM

As the VM runs inside the on-premises network on Hyper-V, I will use the legacy image from

http://cdimage.ubuntu.com/ubuntu-legacy-server/releases/20.04/release/


I will choose to use the entire disk and set up encrypted LVM


Here I will only install the OpenSSH server in order to connect from remote with SSH to the VM.



After the installation from the docker engine, you can check with the docker info command what storage driver will be used from docker.

Docker Engine on Ubuntu supports overlay2, aufs and btrfs storage drivers.
Docker Engine uses the overlay2 storage driver by default. If you need to use aufs instead, you need to configure it manually. See use the AUFS storage driver


Install Docker Engine

Regarding the prerequisites and steps to install I used the following documentation, Ubuntu version 20.04 (LTS) is supported.

Install Docker Engine on Ubuntu
https://docs.docker.com/engine/install/ubuntu/


I will use the Docker repository to install Docker.

$ sudo apt-get install \
    apt-transport-https \
    ca-certificates \
    curl \
    gnupg \
    lsb-release


Add Docker’s official GPG key

$
$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg


Set up the repository

$ echo \
  "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \
  $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null



Install the Docker Engine

$ sudo apt-get update
$ sudo apt-get install docker-ce docker-ce-cli containerd.io

Verify that Docker Engine is installed correctly by running the hello-world image.

$
$ sudo docker run hello-world



Clone Superset’s Github repository

$
$ git clone https://github.com/apache/superset.git

Once that command completes successfully, you should see a new superset folder in your current directory.



Launch Superset through Docker Compose

Navigate to the superset folder and run the following command:

$
$ docker-compose -f docker-compose-non-dev.yml up



I will first have to install docker-compose with the following command

$
$ apt install docker-compose


Now I will run the command again and this time it runs and will startup the container.

$
$ docker-compose -f docker-compose-non-dev.yml up


You should see a wall of logging output from the containers being launched on your machine. Once this output slows, you should have a running instance of Superset on your local machine!


Note: This will bring up superset in a non-dev mode, changes to the codebase will not be reflected. If you would like to run superset in dev mode to test local changes, simply replace the previous command with: docker-compose up, and wait for the superset_node container to finish building the assets.


Your local Superset instance also includes a Postgres server to store your data and is already pre-loaded with some example datasets that ship with Superset. You can access Superset now via your web browser by visiting http://localhost:8088. Note that many browsers now default to https – if yours is one of them, please make sure it uses http.





Links

Superset Documentation
https://apache-superset.readthedocs.io/_/downloads/en/0.34.1/pdf/

Apache Superset is a modern data exploration and visualization platform
https://superset.apache.org/

Apache Superset
https://en.wikipedia.org/wiki/Apache_Superset

Installing Superset Locally Using Docker Compose
https://superset.apache.org/docs/installation/installing-superset-using-docker-compose

Installing Superset from Scratch
https://superset.apache.org/docs/installation/installing-superset-from-scratch