diff options
author | Azat Bahawi <azat@bahawi.net> | 2024-04-21 02:15:42 +0300 |
---|---|---|
committer | Azat Bahawi <azat@bahawi.net> | 2024-04-21 02:15:42 +0300 |
commit | e6ed60548397627bf10f561f9438201dbba0a36e (patch) | |
tree | f9a84c5957d2cc4fcd148065ee9365a0c851ae1c /modules/profiles/dev | |
parent | 2024-04-18 (diff) |
2024-04-21
Diffstat (limited to '')
-rw-r--r-- | modules/profiles/dev/containers.nix | 71 | ||||
-rw-r--r-- | modules/profiles/dev/default.nix (renamed from modules/common/profiles/dev/default.nix) | 22 | ||||
-rw-r--r-- | modules/profiles/dev/gdbinit (renamed from modules/common/profiles/dev/gdbinit) | 0 | ||||
-rw-r--r-- | modules/profiles/dev/ghci.conf (renamed from modules/common/profiles/dev/ghci.conf) | 0 | ||||
-rw-r--r-- | modules/profiles/dev/pystartup.py (renamed from modules/common/profiles/dev/pystartup.py) | 0 | ||||
-rw-r--r-- | modules/profiles/dev/sql.nix (renamed from modules/common/profiles/dev/sql.nix) | 0 |
6 files changed, 87 insertions, 6 deletions
diff --git a/modules/profiles/dev/containers.nix b/modules/profiles/dev/containers.nix new file mode 100644 index 0000000..f75a26b --- /dev/null +++ b/modules/profiles/dev/containers.nix @@ -0,0 +1,71 @@ +{ + config, + lib, + pkgs, + ... +}: +with lib; +let + cfg = config.nixfiles.modules.profiles.dev.containers; +in +{ + options.nixfiles.modules.profiles.dev.containers.enable = + mkEnableOption "Tools for working with containers and container orchestration" + // { + default = config.nixfiles.modules.profiles.dev.enable; + }; + + config = mkIf cfg.enable { + nixfiles.modules = { + common.shell.aliases = { + h = "helm"; + k = "kubectl"; + kns = "kubens"; + ktx = "kubectx"; + b = "buildah"; + }; + podman.enable = true; + }; + + hm = { + home = { + sessionVariables = { + MINIKUBE_HOME = "${config.dirs.config}/minikube"; + MINIKUBE_IN_STYLE = "false"; + WERF_DEV = "true"; + WERF_INSECURE_REGISTRY = "true"; + WERF_LOG_DEBUG = "true"; + WERF_LOG_PRETTY = "false"; + WERF_LOG_VERBOSE = "true"; + WERF_SYNCHRONIZATION = ":local"; + WERF_TELEMETRY = "false"; + }; + + packages = with pkgs; [ + buildah + k9s + kubectl + kubectl-doctor + kubectl-images + kubectl-tree + kubectx + kubelogin-oidc + kubent + kubernetes-helm + kubespy + minikube + skopeo + stern + telepresence2 + werf + ]; + }; + + xdg.dataFile."minikube/config/config.json".text = generators.toJSON { } { + config.Rootless = true; + driver = "podman"; + container-runtime = "cri-o"; + }; + }; + }; +} diff --git a/modules/common/profiles/dev/default.nix b/modules/profiles/dev/default.nix index 6ac1fe6..eab447c 100644 --- a/modules/common/profiles/dev/default.nix +++ b/modules/profiles/dev/default.nix @@ -9,11 +9,7 @@ let cfg = config.nixfiles.modules.profiles.dev; in { - imports = [ - ./containers.nix - ./hidden.nix - ./sql.nix - ]; + imports = attrValues (modulesIn ./.); options.nixfiles.modules.profiles.dev.enable = mkEnableOption "Catch-all profile for stuff related to software development and etc."; @@ -24,7 +20,6 @@ in direnv.enable = true; editorconfig.enable = true; git.client.enable = true; - gnupg.enable = true; nmap.enable = true; wget.enable = true; }; @@ -73,6 +68,11 @@ in sops yq ]; + + language = { + collate = "C"; + messages = "C"; + }; }; xdg.configFile = { @@ -80,5 +80,15 @@ in "ghc/ghci.conf".source = ./ghci.conf; }; }; + + programs.wireshark = { + enable = true; + package = pkgs.wireshark; + }; + + my.extraGroups = [ + "kvm" + "wireshark" + ]; }; } diff --git a/modules/common/profiles/dev/gdbinit b/modules/profiles/dev/gdbinit index e266236..e266236 100644 --- a/modules/common/profiles/dev/gdbinit +++ b/modules/profiles/dev/gdbinit diff --git a/modules/common/profiles/dev/ghci.conf b/modules/profiles/dev/ghci.conf index d672167..d672167 100644 --- a/modules/common/profiles/dev/ghci.conf +++ b/modules/profiles/dev/ghci.conf diff --git a/modules/common/profiles/dev/pystartup.py b/modules/profiles/dev/pystartup.py index adde66c..adde66c 100644 --- a/modules/common/profiles/dev/pystartup.py +++ b/modules/profiles/dev/pystartup.py diff --git a/modules/common/profiles/dev/sql.nix b/modules/profiles/dev/sql.nix index c2d4894..c2d4894 100644 --- a/modules/common/profiles/dev/sql.nix +++ b/modules/profiles/dev/sql.nix |