services.uwsgi.instance

uWSGI configuration. It awaits an attribute type inside which can be either normal or emperor.

For normal mode you can specify pythonPackages as a function from libraries set into a list of libraries. pythonpath will be set accordingly.

For emperor mode, you should use vassals attribute which should be either a set of names and configurations or a path to a directory.

Other attributes will be used in configuration file as-is. Notice that you can redefine plugins setting here.

Type
Json value or lambda
Default
{
  type = "normal";
}
Example
{
  type = "emperor";
  vassals = {
    moin = {
      type = "normal";
      pythonPackages = self: with self; [ moinmoin ];
      socket = "${config.services.uwsgi.runDir}/uwsgi.sock";
    };
  };
}
Declared
<nixpkgs/nixos/modules/services/web-servers/uwsgi.nix>