Docker
Creating and deploying Apache Superset’s customized docker image
Youtube Video To Follow
Steps For youtube
To create custom docker image lets clone superset’s github Repo using following command. To reduce time and resources we will only clone till depth 1 and for this tutorial I am selecting 4.0 branch.
git clone --depth=1 -b 4.0 https://github.com/apache/superset.gitLet’s move to directory
cd superset
Create a dir I am calling it to_be_copied and create following directory structure in it
- to_be_copied_into_assets - {your_project_}images - logo.png - favicon.pngOpen
DockerfilefindWORKDIR /appfor me it is on line 65 (In future it might change). Add following code below itCOPY --chown=superset:superset to_be_copied_into_assets /app/superset/static/assetsCreating docker image using following command
docker build -t shan-superset .Need to do few changes to get our image running open
docker-compose-non-dev.ymland change image name to shan-supersetOnce done lets try to run it using
docker compose -f docker-compose-non-dev.yml upCheck the logs and check if everything is running fine you can use
-dflag as shown below.docker compose -f docker-compose-non-dev.yml up -d