NixOS configuration for HPC cluster
https://docs.hpc.informatik.hs-fulda.de/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
619 B
27 lines
619 B
{ config, ... }:
|
|
|
|
{
|
|
services.nix-serve = {
|
|
enable = true;
|
|
secretKeyFile = config.sops.secrets."cache/privateKey".path;
|
|
};
|
|
|
|
sops.secrets."cache/privateKey" = {
|
|
format = "binary";
|
|
sopsFile = ../../secrets/cache-priv-key.pem;
|
|
};
|
|
|
|
services.nginx = {
|
|
enable = true;
|
|
recommendedProxySettings = true;
|
|
virtualHosts = {
|
|
"cache.${config.networking.domain}" = {
|
|
locations."/".proxyPass = "http://${config.services.nix-serve.bindAddress}:${toString config.services.nix-serve.port}";
|
|
};
|
|
};
|
|
};
|
|
|
|
hpc.hostFile.aliases = [
|
|
"cache.${config.networking.domain}"
|
|
];
|
|
}
|