36 lines
717 B
Nix
36 lines
717 B
Nix
{ config, pkgs, ... }: {
|
|
config.services = {
|
|
nginx = {
|
|
enable = true;
|
|
|
|
recommendedGzipSettings = true;
|
|
recommendedOptimisation = true;
|
|
recommendedProxySettings = true;
|
|
|
|
virtualHosts.home-manager = {
|
|
default = true;
|
|
|
|
locations = {
|
|
"/".extraConfig = ''
|
|
uwsgi_pass unix://${config.services.uwsgi.runDir}/uwsgi.sock;
|
|
include uwsgi_params;
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
|
|
uwsgi = {
|
|
enable = true;
|
|
group = "nginx";
|
|
plugins = [ "python3" ];
|
|
|
|
instance = {
|
|
type = "normal";
|
|
pythonPackages = py: [ py.callPackage ../ui { } ];
|
|
|
|
module = "homemanager.wsgi";
|
|
};
|
|
};
|
|
};
|
|
}
|