Skip to content

Commit

Permalink
Cleanup kubernetes, add kubectl-rook-ceph package, fix/add overlays
Browse files Browse the repository at this point in the history
  • Loading branch information
rodent1 committed Sep 11, 2024
1 parent 2823016 commit b8c9219
Show file tree
Hide file tree
Showing 21 changed files with 215 additions and 208 deletions.
37 changes: 36 additions & 1 deletion flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@
inputs.nixpkgs.follows = "nixpkgs";
};

# Rust toolchain overlay
rust-overlay = {
url = "github:oxalica/rust-overlay";
};

# sops-nix
sops-nix = {
url = "github:Mic92/sops-nix";
Expand Down
62 changes: 52 additions & 10 deletions homes/_modules/kubernetes/default.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,57 @@
{ lib, ... }:
{
imports = [
./kubecm
./kubecolor
./kubectl
./stern
./talhelper
./utilities
];

config,
lib,
pkgs,
...
}:
let
cfg = config.modules.kubernetes;
in
{
options.modules.kubernetes = {
enable = lib.mkEnableOption "kubernetes";
};

config = lib.mkIf cfg.enable {
home.packages =
(with pkgs; [
fluxcd
helmfile
krew
kubecm
kubeconform
kubernetes-helm
kubecolor
kubectl-rook-ceph
minio-client
talhelper
])
++ (with pkgs.unstable; [
kubectl
kubectl-cnpg
kubectl-node-shell
kubectl-view-secret
stern
talosctl
]);

programs.fish = {
interactiveShellInit = ''
fish_add_path $HOME/.krew/bin
${lib.getExe pkgs.unstable.kubecm} completion fish | source
'';

functions = {
k = {
description = "kubectl shorthand";
wraps = "kubectl";
body = builtins.readFile ./functions/k.fish;
};
};

shellAliases = {
kc = "kubecm";
};
};
};
}
File renamed without changes.
24 changes: 0 additions & 24 deletions homes/_modules/kubernetes/krewfile/default.nix

This file was deleted.

33 changes: 0 additions & 33 deletions homes/_modules/kubernetes/kubecm/default.nix

This file was deleted.

15 changes: 0 additions & 15 deletions homes/_modules/kubernetes/kubecolor/default.nix

This file was deleted.

24 changes: 0 additions & 24 deletions homes/_modules/kubernetes/kubectl/default.nix

This file was deleted.

17 changes: 0 additions & 17 deletions homes/_modules/kubernetes/stern/default.nix

This file was deleted.

15 changes: 0 additions & 15 deletions homes/_modules/kubernetes/talhelper/default.nix

This file was deleted.

13 changes: 0 additions & 13 deletions homes/_modules/kubernetes/utilities/default.nix

This file was deleted.

8 changes: 4 additions & 4 deletions homes/_modules/shell/gh/default.nix
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{ pkgs, flake-packages, ... }:
{ pkgs, ... }:
{

config = {
programs.gh = {
enable = true;
extensions = [
flake-packages.${pkgs.system}.gh-copilot
flake-packages.${pkgs.system}.gh-tidy
extensions = with pkgs; [
gh-copilot
gh-tidy
];
};
};
Expand Down
3 changes: 1 addition & 2 deletions homes/_modules/shell/utilities/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ pkgs, flake-packages, ... }:
{ pkgs, ... }:
{
config = {
home.packages = with pkgs; [
Expand All @@ -16,7 +16,6 @@
jo
jq
openssl
flake-packages.${pkgs.system}.shcopy
tlrc
wget
yq-go
Expand Down
3 changes: 0 additions & 3 deletions lib/mkSystem.nix
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
inputs.nix-index-database.hmModules.nix-index
inputs.nixvim.homeManagerModules.nixvim
inputs.sops-nix.homeManagerModules.sops
inputs.krewfile.homeManagerModules.krewfile
];
extraSpecialArgs = {
inherit inputs hostname flake-packages;
Expand Down Expand Up @@ -74,7 +73,6 @@
inputs.nix-index-database.hmModules.nix-index
inputs.nixvim.homeManagerModules.nixvim
inputs.sops-nix.homeManagerModules.sops
inputs.krewfile.homeManagerModules.krewfile
];
extraSpecialArgs = {
inherit inputs hostname flake-packages;
Expand Down Expand Up @@ -120,7 +118,6 @@
inputs.nix-index-database.hmModules.nix-index
inputs.nixvim.homeManagerModules.nixvim
inputs.sops-nix.homeManagerModules.sops
inputs.krewfile.homeManagerModules.krewfile
];
extraSpecialArgs = {
inherit inputs hostname flake-packages;
Expand Down
Loading

0 comments on commit b8c9219

Please sign in to comment.