Deploy guide · runtime = "python"
Ship Flask in ~2 minutes.
Flask is Python's lightweight web framework — minimal core, blueprints for structure, and Werkzeug under the hood. Percher detects `flask` in `requirements.txt`/`pyproject.toml` and ships it on the Python runtime via Nixpacks.
Why Percher fits
- Flask's request lifecycle is short and synchronous — fits Percher's container model with no async surprises.
- Set `mode = "pocketbase"` and a managed PocketBase comes up alongside the app; auth, file storage, and SQLite without wiring up Postgres.
Quick start
bunx percher create my-app --template flask
cd my-app
bunx percher publishThe first command scaffolds a working Flask project plus a percher.toml. Publish builds and deploys it, then prints the live URL.
percher.toml
The canonical config for a Flask app on Percher. bunx percher init generates this automatically when it detects Flask in your project.
[app]
name = "my-app"
runtime = "python"
framework = "flask"
[web]
port = 5000
health = "/health"
[data]
mode = "pocketbase"
Common gotchas
- Production needs a WSGI server — `gunicorn -b 0.0.0.0:${PORT} app:app`, not `flask run`. Add `gunicorn` to your requirements.
- Add a `/health` route that returns `({"status": "ok"}, 200)`; the deploy health check is strict about the 200 response.