mirror of
https://github.com/tuxdotrs/nixos-config.git
synced 2025-07-07 02:06:34 +05:30
44 lines
870 B
Nix
44 lines
870 B
Nix
{
|
|
username,
|
|
lib,
|
|
config,
|
|
...
|
|
}: let
|
|
home = import ./home.nix;
|
|
in {
|
|
services = {
|
|
glance = {
|
|
enable = true;
|
|
openFirewall = true;
|
|
settings = {
|
|
server = {
|
|
host = "0.0.0.0";
|
|
port = 5678;
|
|
};
|
|
branding = {
|
|
custom-footer = "<p><a href='https://tux.rs'>${username}</a></p>";
|
|
};
|
|
pages = [
|
|
home.page
|
|
];
|
|
};
|
|
};
|
|
|
|
nginx = {
|
|
enable = lib.mkForce true;
|
|
virtualHosts = {
|
|
"home.tux.rs" = {
|
|
forceSSL = true;
|
|
useACMEHost = "tux.rs";
|
|
locations = {
|
|
"/" = {
|
|
proxyPass = "http://${config.services.glance.settings.server.host}:${toString config.services.glance.settings.server.port}";
|
|
proxyWebsockets = true;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
}
|