Dash Deployment

After trying for many days, I still could not deploy a basic dash app on my VPS server.

Attached is the snapshot from chrome developer tool. I deployed it at this web address:
http://dash.eprojecttrackers.com/pythonapp/dash/

However, there are many 404 errors as the app tried to load dash components. See snapshot.

I could get a basic Flask app to work but no luck with Dash. I just get a ‘loading…’ message.

Your failed http requests appear to be missing the “/pythonapp/” part of the URI. This can happen when you have some middleware or a proxy server adding a URL prefix that the Dash app is unaware of.

You might need to provide a value for the Dash constructor param ‘requests_pathname_prefix’. Maybe it wan’t to be “/pythonapp/”? But it’s been a while since I’ve had my head in that space and I might be getting it wrong.

This comment could be helpful: Deploy Dash on apache server [solved!]

THANKS VERY MUCH!!! It worked!! :+1:

I had almost given up on deploying dash … :smiley:

app = dash.Dash(
name,
server=server,
routes_pathname_prefix=’/dash/’,
requests_pathname_prefix=’/pythonapp/dash/’
)

1 Like