Quantcast
Channel: 🎛️ Dash - Plotly Community Forum
Viewing all articles
Browse latest Browse all 6271

Serving CSS for deployment on Apache2 server doesn't work

$
0
0

@sschneider wrote:

I’m trying to host a Dash app on a Apache2 server, but serving another CSS file I have placed under the assets folder is not working. This topic did not really help me fix that issue.

I have this structure basically:
And my directory structure is:

├── app.py
├── assets
│   └── bulma.css

which works with the css styles, when I run python app.py locally. On the server the app itself runs fine, but it’s not working to load the css file in assets.

My apache .conf file is

<VirtualHost *:80>
                ServerName <IP>
                ServerAdmin <MAIL>
                WSGIScriptAlias / /var/www/app/App.wsgi
                <Directory /var/www/app/>
                        Order allow,deny
                        Allow from all
                </Directory>
                ErrorLog ${APACHE_LOG_DIR}/App-error.log
                LogLevel warn
                CustomLog ${APACHE_LOG_DIR}/App-access.log combined
</VirtualHost>

My app.py is basically (aside from layout) this:

app = dash.Dash(external_stylesheets=external_stylesheets)
server = app.server
app.config.supress_callback_exceptions = True

My App.wsgi is:

 c#!/usr/bin/python3.6
import sys
import logging
logging.basicConfig(stream=sys.stderr)
sys.path.insert(0,"/var/www/app/")

from gd_analysis.app import server as application

Does anyone have an idea what I’m doing wrong or missing here?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 6271

Latest Images

Trending Articles



Latest Images