44 lines
1.1 KiB
Nix
44 lines
1.1 KiB
Nix
{ config, lib, ... }:
|
|
let
|
|
cfg = config.services.az-heimdall;
|
|
volumePath = "/mnt/server-data/heimdall";
|
|
in
|
|
{
|
|
options = {
|
|
services.az-heimdall.enable = lib.mkEnableOption "Enable Heimdall";
|
|
};
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
services.az-docker.enable = true;
|
|
|
|
fileSystems."${volumePath}" = {
|
|
device = "10.7.89.108:server_data/heimdall";
|
|
fsType = "nfs";
|
|
options = [
|
|
"hard"
|
|
"noatime"
|
|
"rw"
|
|
];
|
|
};
|
|
virtualisation.oci-containers = {
|
|
backend = "docker";
|
|
containers."heimdall" = {
|
|
# https://fleet.linuxserver.io/image?name=linuxserver/heimdall
|
|
image = "linuxserver/heimdall:2.6.1@sha256:36517034b0b77f86d87aac06898639e90d1f8e1cc4350bd5928cd098eed7053c";
|
|
autoStart = true;
|
|
environment = {
|
|
TZ = "Europe/Zurich";
|
|
PUID = "1000";
|
|
PGID = "100";
|
|
};
|
|
ports = [ "8081:80" ];
|
|
volumes = [
|
|
"/etc/localtime:/etc/localtime:ro"
|
|
"${volumePath}:/config"
|
|
];
|
|
extraOptions = [ "--log-opt=tag='heimdall'" ];
|
|
};
|
|
};
|
|
};
|
|
}
|