feat: centralize longhorn config
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
{
|
{
|
||||||
|
pkgs,
|
||||||
config,
|
config,
|
||||||
meta,
|
meta,
|
||||||
...
|
...
|
||||||
@@ -14,4 +15,14 @@
|
|||||||
else "https://${meta.server-addr}:6443";
|
else "https://${meta.server-addr}:6443";
|
||||||
extraFlags = ["--disable=servicelb" "--disable=traefik" "--node-ip ${meta.zt-ip}" "--flannel-iface ztxh6lvd6t" "--flannel-backend=host-gw" "--tls-san ${meta.zt-ip}"];
|
extraFlags = ["--disable=servicelb" "--disable=traefik" "--node-ip ${meta.zt-ip}" "--flannel-iface ztxh6lvd6t" "--flannel-backend=host-gw" "--tls-san ${meta.zt-ip}"];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# For longhorn
|
||||||
|
environment.systemPackages = [ pkgs.nfs-utils ];
|
||||||
|
services.openiscsi = {
|
||||||
|
enable = true;
|
||||||
|
name = "iqn.2016-04.com.open-iscsi:${config.networking.hostName}";
|
||||||
|
};
|
||||||
|
systemd.tmpfiles.rules = [
|
||||||
|
"L+ /usr/local/bin - - - - /run/current-system/sw/bin/"
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -35,7 +35,6 @@
|
|||||||
jq
|
jq
|
||||||
ripgrep
|
ripgrep
|
||||||
fd
|
fd
|
||||||
nfs-utils
|
|
||||||
];
|
];
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
@@ -65,14 +64,5 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# For longhorn
|
|
||||||
services.openiscsi = {
|
|
||||||
enable = true;
|
|
||||||
name = "iqn.2016-04.com.open-iscsi:${config.networking.hostName}";
|
|
||||||
};
|
|
||||||
systemd.tmpfiles.rules = [
|
|
||||||
"L+ /usr/local/bin - - - - /run/current-system/sw/bin/"
|
|
||||||
];
|
|
||||||
|
|
||||||
system.stateVersion = "24.11";
|
system.stateVersion = "24.11";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,15 +21,6 @@
|
|||||||
services.openssh.enable = true;
|
services.openssh.enable = true;
|
||||||
services.qemuGuest.enable = true;
|
services.qemuGuest.enable = true;
|
||||||
|
|
||||||
# For longhorn
|
|
||||||
services.openiscsi = {
|
|
||||||
enable = true;
|
|
||||||
name = "iqn.2016-04.com.open-iscsi:${meta.hostname}";
|
|
||||||
};
|
|
||||||
systemd.tmpfiles.rules = [
|
|
||||||
"L+ /usr/local/bin - - - - /run/current-system/sw/bin/"
|
|
||||||
];
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
git
|
git
|
||||||
neovim
|
neovim
|
||||||
@@ -37,7 +28,6 @@
|
|||||||
jq
|
jq
|
||||||
ripgrep
|
ripgrep
|
||||||
fd
|
fd
|
||||||
nfs-utils
|
|
||||||
];
|
];
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
|
|||||||
Reference in New Issue
Block a user