Skip to content
Andrea Peltrin edited this page Oct 27, 2023 · 4 revisions

Pick your deploy method

Given that Coldsweat is a Flask application we can leverage the aboundance of documentation available. Please see Flask Deploying to Production page to pick your deploy solution of choice.

Loading static assets

When using the default development web server, Coldsweat serves all static assets needed to run the web UI: CSS styles, JavaScript code, and images. This is convenient while writing software because developer keeps changing these file and she wants to see the changes to happen immediately.

However, when you deploy Coldsweat you want those assets to be loaded from the web server of choice, which is more efficient in serving static files. To do that Coldsweat integrates Flask CDN extension which lets you specify a different URL as "base path" for all assets.

This is done via the FLASK_CDN_DOMAIN environment variable:

export FLASK_CDN_DOMAIN="cdn.example.com"

Or by adding CDN_DOMAIN to Coldsweat config.toml file:

# ...Other settings
CDN_DOMAIN="cdn.example.com"

See Flask-CDN Static Asset URLs for more information.