A Flask server to serve single-page applications deployed using the lightning strategy on Azure Table Storage. Designed to work with Ember-cli-deploy-azure, but should be compatible with any lightning strategy deployment on Azure Table Storage via configuration. Developed with Python 2.7
It is recommended that you install and run azure_lightning_flask inside of a virtualenv
virtualenv venv . venv/bin/activate
pip install azure_lightning_flask
Download the application files and in the root directory run
pip install -r requirements.txt python setup.py install
Configure the application by setting environment variables. All application configuration variables without a default must be set.
This application serves content from Azure Storage Table requiring an Azure account and a storage table to be setup for some of the required configuration.
Environment Variable | Usage | Default |
---|---|---|
AZURE_STORAGE_ACCOUNT | The name of the Azure Storage account to be used | None (Must be set) |
AZURE_STORAGE_KEY | The key for the given Azure Storage account | None (Must be set) |
AZURE_STORAGE_TABLE | The name of the table where revisions are stored | emberdeploy |
AZURE_STORAGE_TABLE_P ARTITION_KEY | The partition key to search under | manifest |
APP_NAME | The name of the application being served | None (Must be set) |
REVISION_PARAMETER | The query parameter used to request specific revisions | index_key |
After it is configured, run the application with
azure_lightning_flask
Flask configuration values can also be set via environment variables as the environment is merged into the flask configuration via flask-env.
python setup.py nosetests