1. Adam Gomaa
  2. faf


faf /

Filename Size Date modified Message
1.2 KB
186 B

faf - fire and forget web apps

Basic idea is a wrapper for simple flask apps that require very little infrastructure to run - specifically, no database.

Look in a directory for application directories. Each is expected to have a requirements.txt, a setup.py, and to be installable via pip. Install the requirements and the app, and host using werkzeug's DispatcherMiddleware at the directory name. The directory name is required to be the same as the application's package name, so this isn't appropriate for situations where multiple instances of an application can be hosted at separate URLs. The application must make a wsgi app available as pkgname.app; typically a Flask app for my use case, but there's no reason it shouldn't work with any WSGI callable.

By default, the app dir is ~/.local/share/faf/. A FAF_SETTINGS environment variable can be used to provide a settings filename. Faf expects to run in a virtualenv - it runs pip without sudo, so if sys.prefix is /usr or /usr/local, it won't work.

There's a minimal web UI that lists the apps and allows you to install them if not already installed. There's no authn/authz, the access pcontrol is write access to the app directory.