Tags

Items in Blog tagged with [python]
All items tagged with [python]

Embedding a Python Application in uWSGI

The uWSGI logo WyWeb (my software that is running this website right now) uses uWSGI to communicate with the server. Previously, WyWeb was a loose collection of python files that needed to be run in a virtualenv and started with a separate uWSGI command and a configuration file. This was fine when WyWeb was fairly bare bones and only used by me, but as I began to expand its functionality, I wanted to easily share it with others. Having people clone a git repo, manage dependencies, manually set up systemd services, and configure a server is too much to ask. Luckily, I found uWSGI’s official documentation on how to embed a python script in a standalone binary! Unluckily, the instructions are out-of-date at best, objectively wrong at worst, and written in a tone so intolerable that I thought I had been catapulted back to the heckin’ epicsause year of our Lord 2010. Luckily for you I am recording my steps for success so that hopefully you can be spared the torment I have endured.