Skip to content

feat(service): add apache superset service #4891

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 17 commits into from
May 20, 2025

Conversation

nktnet1
Copy link
Contributor

@nktnet1 nktnet1 commented Jan 21, 2025

Changes

  • added AirBnB's Apache/Superset (unofficial) template

Update 20/05/2025 - Added video demo:

superset-coolify-56mb.webm

Apache Superset is a popular "Data Visualization and Data Exploration Platform". Currently, it has ~64k stars on GitHub.

Unfortunately, superset does not officially support docker-compose in production:


This template uses an unofficial docker image to allow for production docker deployment. However, this in itself is also quite popular, with nearly 1k stars on GitHub:

and over 5 million downloads on DockerHub:


There are multiple flavours of superset (unofficial) that are supported, e.g.

  • celery
  • postgresql (I chose this one)
  • mysql
  • sqlite (probably not prod)

However, given that it's "unofficial", I wanted to run this through the Coolify team before proceeding with the superset-unofficial-with-celery and superset-unofficial-with-mysql templates, in case the policy is to not accept unofficial images.


NOTE: for the first launch, you will need to enter the superset container using Coolify's terminal feature to run

superset-init

to register the admin user and database. Alternatively, the superset-demo command will do the same, and additionally load demo database/charts/dashboards into the superset instance.

I'm happy to contribute this to documentations-coolify if it gets the green light.


@nktnet1 nktnet1 changed the title feat(template): added superset unofficial with postgres feat(template): added apache superset (unofficial) with postgres Jan 21, 2025
@peaklabs-dev peaklabs-dev added the ⚙️ Service Issues requesting or PRs adding/fixing service templates. label Jan 21, 2025
@nktnet1

This comment was marked as resolved.

@nktnet1

This comment was marked as resolved.

@nktnet1 nktnet1 marked this pull request as ready for review January 28, 2025 13:15
@andrasbacsai andrasbacsai deleted the branch coollabsio:next May 9, 2025 06:31
@andrasbacsai
Copy link
Member

It was a mistake, sorry. I recreated the next branch and it auto-closed this PR.

@andrasbacsai andrasbacsai reopened this May 9, 2025
@peaklabs-dev
Copy link
Member

Thanks for the PR. I think this is not fully working just yet. When running superset init it throws and error and also there is no user created via ENVs as far as I know, so nobody can log in can you please fix these things.

@peaklabs-dev peaklabs-dev added the 💤 Waiting for changes PRs awaiting changes from the author. label May 19, 2025
@nktnet1
Copy link
Contributor Author

nktnet1 commented May 19, 2025

Hey @peaklabs-dev,

Are you able to show me the error you're getting from superset-init? (note the -)

Our team actually has this template running in production, so that's odd. I'll try again to see if anything changed in the latest docker image.

also there is no user created via ENVs as far as I know, so nobody can log in can you please fix these things

I don't think superset supports creating an admin user through ENV - it must be done through the superset init command.

@nktnet1
Copy link
Contributor Author

nktnet1 commented May 19, 2025

@peaklabs-dev yep, tested it just now and it works.

I also tested superset init instead of superset-init, and it does result in the error I assume you were getting. This is because you need to run a few other commands before that.

Here's what the docker version's superset-init command runs:

#!/bin/bash
set -eo pipefail

# Create an admin user
flask fab create-admin $@

# Initialize the database
superset db upgrade

# Create default roles and permissions
superset init

Demo:

superset-coolify-56mb.webm

@peaklabs-dev
Copy link
Member

Thanks. Maybe you can add an entrypoint script that runs this automatically?

@nktnet1
Copy link
Contributor Author

nktnet1 commented May 19, 2025

Thanks. Maybe you can add an entrypoint script that runs this automatically?

I think that might work, but I'm hesitant because

  1. it goes against superset's setup instructions, i.e. will need to be managed and maintained by Coolify and could cause confusion
  2. it takes away some flexibility, e.g. loading demos instead of the basic init
  3. we'll need to find a way to avoid running the setup (or exit early) each time the container restarts

If you're happy with the above, then I can help look into it.
Not sure if there will be an easy way to do number 3 though.

@peaklabs-dev
Copy link
Member

I guess it make sense not to automate it. Can you create a docs PR that tells the user to run superset-init in the superset Container and then everything will work (just tried it and that works perfectly)

Thanks for the PR. I will merge it and fix a few small things.

@peaklabs-dev peaklabs-dev changed the title feat(template): added apache superset (unofficial) with postgres feat(service): add apache superset service May 20, 2025
@peaklabs-dev peaklabs-dev merged commit 4f04951 into coollabsio:next May 20, 2025
1 check passed
@github-actions github-actions bot removed ⚙️ Service Issues requesting or PRs adding/fixing service templates. 💤 Waiting for changes PRs awaiting changes from the author. labels May 20, 2025
@nktnet1
Copy link
Contributor Author

nktnet1 commented May 21, 2025

Documentation added here:

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants