Join us at the Everyday AI Conference in London, New York & Bengaluru! REGISTER NOW

assign flask server to dash app

vishal
Level 2
Level 2
assign flask server to dash app

Locally we use

 

server = Flask(__name__)
app = dash.Dash(__name__, server)



Is there a way to assign flask server to dash app?

0 Kudos
4 Replies
fchataigner2
Dataiker
Dataiker

Hi,

when you run a Dash webapp in DSS,  DSS actually creates the Flask server and assigns it to the Dash app, exactly like you're doing. This means that as a DSS user you won't have access to the Flask server creation. What Flask options do you need to control?

vishal
Level 2
Level 2
Author

I am trying to init SQLAlchemy,
and login manager from flask_login.

can I directly use server the way I can use app without instiating it?

0 Kudos
vishal
Level 2
Level 2
Author

I found it.
All this while I was creating a flask instance like:

server = Flask(__name__)

all I had to do was use it from app ie.,

server = app.server.

Thanks @fchataigner2 , your explanation helped!

CoreyS
Community Manager
Community Manager

We’re glad you were able to figure it out @vishal!

Looking for more resources to help you use Dataiku effectively and upskill your knowledge? Check out these great resources: Dataiku Academy | Documentation | Knowledge Base

A reply answered your question? Mark as ‘Accepted Solution’ to help others like you!