rename options
This commit is contained in:
@@ -81,7 +81,7 @@
|
||||
searxng.enable = true;
|
||||
};
|
||||
|
||||
virtualization = {
|
||||
containers = {
|
||||
traefik.enable = true;
|
||||
jellyfin.enable = true;
|
||||
"esotericbytes.com".enable = true;
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
};
|
||||
|
||||
|
||||
virtualization = {
|
||||
containers = {
|
||||
|
||||
wyoming = {
|
||||
enable = mkDefault false;
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, sops-nix, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.authentik.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.authentik.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.authentik.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.authentik.enable {
|
||||
|
||||
sops.secrets."authentik/dbpass" = {};
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.code-server.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.code-server.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.code-server.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.code-server.enable {
|
||||
|
||||
containers.code-server = {
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.gitea.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.gitea.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.gitea.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.gitea.enable {
|
||||
|
||||
networking = {
|
||||
hosts."192.168.100.20" = [ "gitea.esotericbytes.com" ];
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.gitlab.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.gitlab.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.gitlab.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.gitlab.enable {
|
||||
|
||||
sops.secrets = {
|
||||
"gitlab/db_pass" = {};
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.homeassistant = {
|
||||
options.sysconfig.containers.homeassistant = {
|
||||
enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.homeassistant.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.homeassistant.enable {
|
||||
|
||||
containers.home-assistant = {
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.jellyfin.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.jellyfin.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.jellyfin.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.jellyfin.enable {
|
||||
|
||||
containers.jellyfin = {
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.keycloak.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.keycloak.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.keycloak.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.keycloak.enable {
|
||||
|
||||
sops.secrets."keycloak/dbpass" = {};
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
{ config, lib, pkgs, nix-minecraft, ... }: {
|
||||
|
||||
options.sysconfig = {
|
||||
virtualization.minecraft.enable = lib.options.mkOption {
|
||||
containers.minecraft.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.minecraft.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.minecraft.enable {
|
||||
|
||||
networking = {
|
||||
firewall = {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.n8n.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.n8n.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.n8n.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.n8n.enable {
|
||||
|
||||
containers.n8n = {
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
default = false;
|
||||
};
|
||||
|
||||
virtualization.netbird = {
|
||||
containers.netbird = {
|
||||
enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
@@ -32,7 +32,7 @@
|
||||
};
|
||||
|
||||
networking = {
|
||||
firewall = lib.mkIf config.sysconfig.virtualization.netbird.enable {
|
||||
firewall = lib.mkIf config.sysconfig.containers.netbird.enable {
|
||||
allowedUDPPorts = [ 3478 ];
|
||||
allowedUDPPortRanges = [{ from = 51100; to = 56100; }];
|
||||
|
||||
@@ -44,10 +44,10 @@
|
||||
nat.internalInterfaces = [ "ve-netbird" "wt0" ];
|
||||
};
|
||||
|
||||
sops.secrets."netbird/coturnPass" = lib.mkIf config.sysconfig.virtualization.netbird.enable {};
|
||||
sops.secrets."netbird/coturnPass" = lib.mkIf config.sysconfig.containers.netbird.enable {};
|
||||
|
||||
|
||||
containers.netbird = lib.mkIf config.sysconfig.virtualization.netbird.enable {
|
||||
containers.netbird = lib.mkIf config.sysconfig.containers.netbird.enable {
|
||||
|
||||
autoStart = true;
|
||||
privateNetwork = true;
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.nextcloud.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.nextcloud.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.nextcloud.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.nextcloud.enable {
|
||||
|
||||
sops.secrets."nextcloud/pass" = {};
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization."esotericbytes.com".enable = lib.mkOption {
|
||||
options.sysconfig.containers."esotericbytes.com".enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization."esotericbytes.com".enable {
|
||||
config = lib.mkIf config.sysconfig.containers."esotericbytes.com".enable {
|
||||
|
||||
containers.esotericbytes-com = {
|
||||
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
{ config, lib, pkgs, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.novnc.enable = lib.mkOption {
|
||||
options.sysconfig.containers.novnc.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.novnc.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.novnc.enable {
|
||||
|
||||
networking = {
|
||||
firewall.interfaces."ve-novnc" = lib.mkIf config.sysconfig.virtualization.novnc.enable {
|
||||
firewall.interfaces."ve-novnc" = {
|
||||
allowedTCPPorts = [ 5900 ];
|
||||
allowedUDPPorts = [ 5900 ];
|
||||
};
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.ntfy.enable = lib.mkOption {
|
||||
options.sysconfig.containers.ntfy.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.ntfy.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.ntfy.enable {
|
||||
|
||||
containers.ntfy = {
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
{ config, lib, pkgs, nixpkgs-us, ... }: {
|
||||
{ config, lib, nixpkgs-us, ... }: {
|
||||
|
||||
options = {
|
||||
sysconfig.virtualization.openwebui.enable = lib.options.mkOption {
|
||||
sysconfig.containers.openwebui.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.openwebui.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.openwebui.enable {
|
||||
|
||||
containers.openwebui = {
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
|
||||
services.open-webui = {
|
||||
enable = true;
|
||||
#package = pkgs.open-webui;
|
||||
package = let
|
||||
pkgs-us = import nixpkgs-us {
|
||||
system = "x86_64-linux";
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.rustdesk.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.rustdesk.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.rustdesk.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.rustdesk.enable {
|
||||
|
||||
/*networking = {
|
||||
firewall.allowedTCPPorts = [ 21115 21116 21117 21118 21119 ];
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, self, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.sandbox.enable = lib.mkOption {
|
||||
options.sysconfig.containers.sandbox.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.sandbox.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.sandbox.enable {
|
||||
|
||||
networking = {
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.traefik.enable = lib.options.mkOption {
|
||||
options.sysconfig.containers.traefik.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.traefik.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.traefik.enable {
|
||||
|
||||
networking = {
|
||||
hosts."192.168.100.11" = [
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.wyoming = {
|
||||
options.sysconfig.containers.wyoming = {
|
||||
enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
@@ -23,7 +23,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.virtualization.wyoming.enable {
|
||||
config = lib.mkIf config.sysconfig.containers.wyoming.enable {
|
||||
|
||||
containers.wyoming = {
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
hostAddress = "192.168.100.10";
|
||||
localAddress = "192.168.100.26";
|
||||
|
||||
bindMounts = lib.mkIf config.sysconfig.virtualization.wyoming.faster-whisper {
|
||||
bindMounts = lib.mkIf config.sysconfig.containers.wyoming.faster-whisper {
|
||||
"/dev/nvidia0" = {
|
||||
hostPath = "/dev/nvidia0";
|
||||
isReadOnly = false;
|
||||
@@ -55,7 +55,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
allowedDevices = lib.mkIf config.sysconfig.virtualization.wyoming.faster-whisper [
|
||||
allowedDevices = lib.mkIf config.sysconfig.containers.wyoming.faster-whisper [
|
||||
{
|
||||
node = "/dev/nvidia0";
|
||||
modifier = "rw";
|
||||
@@ -86,7 +86,7 @@
|
||||
|
||||
services.wyoming = {
|
||||
|
||||
piper = lib.mkIf config.sysconfig.virtualization.wyoming.piper {
|
||||
piper = lib.mkIf config.sysconfig.containers.wyoming.piper {
|
||||
|
||||
servers.piper = {
|
||||
enable = true;
|
||||
@@ -95,7 +95,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
openwakeword = lib.mkIf config.sysconfig.virtualization.wyoming.openwakeword {
|
||||
openwakeword = lib.mkIf config.sysconfig.containers.wyoming.openwakeword {
|
||||
enable = true;
|
||||
uri = "tcp://0.0.0.0:11432";
|
||||
|
||||
@@ -105,7 +105,7 @@
|
||||
];
|
||||
};
|
||||
|
||||
faster-whisper = lib.mkIf config.sysconfig.virtualization.wyoming.faster-whisper {
|
||||
faster-whisper = lib.mkIf config.sysconfig.containers.wyoming.faster-whisper {
|
||||
servers.whisper = {
|
||||
enable = true;
|
||||
device = "auto";
|
||||
@@ -115,7 +115,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
satellite = lib.mkIf config.sysconfig.virtualization.wyoming.satellite {
|
||||
satellite = lib.mkIf config.sysconfig.containers.wyoming.satellite {
|
||||
enable = true;
|
||||
uri = "tcp://0.0.0.0:11431";
|
||||
#user = "nathan";
|
||||
|
||||
@@ -1,4 +1,9 @@
|
||||
{ ... }: {
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.virtualization.enable = with lib; mkOption {
|
||||
type = with types; bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
imports = let
|
||||
dir = builtins.readDir ./.;
|
||||
@@ -7,7 +12,7 @@
|
||||
(builtins.attrNames dir)
|
||||
);
|
||||
|
||||
config = {
|
||||
config = lib.mkIf config.sysconfig.virtualisation.enable {
|
||||
programs.virt-manager.enable = true;
|
||||
|
||||
virtualisation.libvirtd.enable = true;
|
||||
|
||||
Reference in New Issue
Block a user