not able to set up db for persistence data in superset

Viewed 311

I installed superset thanks to the docker-compose file I found here https://github.com/apache/superset

I setup the db service like that

enter image description here

So first I launch db docker-compos up db, the container (named superset_db) is up and running

enter image description here

I retrieve the IP of superset_db then I put it in the superser_config.py file in line 170

SQLALCHEMY_DATABASE_URI = 'postgresql+psycopg2://superset:superset@192.168.16.2:5432/superset'

192.168.16.2 is the Ip address of superset_db container

Then I launch the entire docker-compose file docker-compose up --build but installation failed, after a moment I had this error message

enter image description here

It seems that superset cannot reach superset_db, So I try to reach superset_db from my host with psql and I succeed :

enter image description here

Then I commented the SQLALCHEMY_DATABASE_URI in superser_config.py this time installation of superset was successfull and then inside the superset container I tried to reach superset db with psql command and it works

So why the parameter

SQLALCHEMY_DATABASE_URI = 'postgresql+psycopg2://superset:superset@192.168.16.2:5432/superset

block the installation of superset ? Any comment will be really appreciate

Thanks

0 Answers
Related