Skip to main content
# [Flask-Run](https://github.com/salsita/flask-run) <a href='https://github.com/salsita'><img align='right' title='Salsita' src='https://www.google.com/a/cpanel/salsitasoft.com/images/logo.gif?alpha=1' /></a>

Flask-based web application runner.

[![Latest Version](https://pypip.in/version/Flask-Run/badge.svg)]
(https://pypi.python.org/pypi/Flask-Run/)
[![Downloads](https://pypip.in/download/Flask-Run/badge.svg)]
(https://pypi.python.org/pypi/Flask-Run/)
[![Supported Python versions](https://pypip.in/py_versions/Flask-Run/badge.svg)]
(https://pypi.python.org/pypi/Flask-Run/)
[![License](https://pypip.in/license/Flask-Run/badge.svg)]
(https://pypi.python.org/pypi/Flask-Run/)


## Supported Platforms

* [Python](http://www.python.org/) >= 2.7, 3.3
* [Flask](http://flask.pocoo.org/) >= 0.9


## Get Started

Install using [pip](https://pip.pypa.io/) or [easy_install](http://pythonhosted.org/setuptools/easy_install.html):
```bash
pip install Flask-Run
easy_install Flask-Run
```

## Example:

#### Flask application: `app.py`

```python
#!/usr/bin/env python

"""Flask-based web application."""

__all__ = 'app'.split()

import flask
from config import Config

app = None

def create_app(config=Config):
app = flask.Flask(__name__)

app.config.from_object(config)

return app

if __name__ == '__main__':
from flask.ext.run import run
run(create_app, Config)
```

#### Flask configuration: `config.py`

See [sample flask configuration `config.py](https://github.com/salsita/flask-config#flask-configuration-configpy)
from [flask-config package](https://github.com/salsita/flask-config)
that supports listing and selecting environment configurations.

#### Usage:

```
usage: app.py [-h] [-b [HOST|:PORT]] [-r] [-R] [-d] [-D] [-e ENV]
[-E [SHOW_ENV]] [-g]

runs Flask-based web application using Python WSGI reference server

optional arguments:
-h, --help show this help message and exit
-b [HOST|:PORT], --bind [HOST|:PORT]
bind to HOST:PORT (default: 127.0.0.1:5000)
-r, --reload reload server on code change (default in development)
-R, --no-reload do not reload server on code change
-d, --debug show debugger on exception (default in development)
-D, --no-debug do not show debugger on exception
-e ENV, --env ENV select environment config (default: development)
-E [SHOW_ENV], --show-env [SHOW_ENV]
show environment config and exit (*: all, default: development)
-g, --gen-key generate a good secret key and exit

optional environment variables:
APP_ENV select environment configuration
DATABASE_URL sqlalchemy database uri including credentials
SECRET_KEY secret key for signing session cookies

available environment configurations (*: active):
* dev | development
prod | production
qa | test | testing
stage | staging
try | experimental

```

## Changelog

### 0.1.3

#### Fixes

- Fix package setup on Python 3.

### 0.1.2

#### Fixes

- Fix package setup to not require dependencies preinstalled.

### 0.1.0

#### Features

* Initial release.

Metadata

Release files for Flask-Run 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Flask-Run 0.1.3
File Size Uploaded
Flask-Run-0.1.3.zip 7.0 kB Details

Release files / Flask-Run-0.1.3.zip

Download URL Flask-Run-0.1.3.zip
Size 7.0 kB
Tags Source
SHA-256 checksum
How to use checksums
1dea196fb25c9d68a65fb76b1616b7182bcfc7aaa42c2ea1c5657b48bfc7c04a
BLAKE2b-256 checksum
How to use checksums
16ee86787f4a6187e94cbaf50158fd2e13c560172b9a5ff447b1a9979d251df1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.3 This release

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page