feat(inbucket): Expose on tailnet
This commit is contained in:
parent
835aea667c
commit
0f2a90ec8a
6 changed files with 77 additions and 73 deletions
|
@ -2,6 +2,5 @@
|
|||
imports = [
|
||||
./ingress.nix
|
||||
./longhorn-volume.nix
|
||||
./nfs-volume.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,47 +0,0 @@
|
|||
{ lib, config, ... }:
|
||||
let
|
||||
nfsVolumeOpts = { name, ... }: {
|
||||
options = {
|
||||
path = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
};
|
||||
in
|
||||
{
|
||||
options = {
|
||||
lab.nfsVolumes = lib.mkOption {
|
||||
type = with lib.types; attrsOf (submodule nfsVolumeOpts);
|
||||
default = { };
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
kubernetes.resources = {
|
||||
persistentVolumes = builtins.mapAttrs
|
||||
(name: nfsVolume: {
|
||||
spec = {
|
||||
capacity.storage = "1Mi";
|
||||
accessModes = [ "ReadWriteMany" ];
|
||||
|
||||
nfs = {
|
||||
server = "lewis.dmz";
|
||||
path = "/mnt/longhorn/persistent/${nfsVolume.path}";
|
||||
};
|
||||
};
|
||||
})
|
||||
config.lab.nfsVolumes;
|
||||
|
||||
persistentVolumeClaims = builtins.mapAttrs
|
||||
(name: nfsVolume: {
|
||||
spec = {
|
||||
accessModes = [ "ReadWriteMany" ];
|
||||
storageClassName = "";
|
||||
resources.requests.storage = "1Mi";
|
||||
volumeName = name;
|
||||
};
|
||||
})
|
||||
config.lab.nfsVolumes;
|
||||
};
|
||||
};
|
||||
}
|
Reference in a new issue