refactor: remove secrets dir from repo to submodule
Some checks failed
Check Formatting of Files / Check-Formatting (push) Failing after 38s

This commit is contained in:
Price Hiller 2024-09-26 23:43:49 -05:00
parent a20a554d00
commit 2fae212062
Signed by: Price
GPG Key ID: C3FADDE7A8534BEB
13 changed files with 55 additions and 195 deletions

5
.gitmodules vendored
View File

@ -21,4 +21,7 @@
url = https://github.com/chisui/zsh-nix-shell
[submodule "dots/.config/zsh/config/plugins/powerlevel10k"]
path = users/price/dots/.config/zsh/config/plugins/powerlevel10k
url = https://github.com/romkatv/powerlevel10k.git
url = https://github.com/romkatv/powerlevel10k.git
[submodule "secrets"]
path = secrets
url = ssh://gitea@git.orion-technologies.io:2220/Price/Secrets.git

View File

@ -56,11 +56,11 @@
]
},
"locked": {
"lastModified": 1725738410,
"narHash": "sha256-7qb9cJrHnWSs1UPa76GKGhZTzq9r01MPrLcM5ky36cI=",
"lastModified": 1727370667,
"narHash": "sha256-i0yF7uAE0Msn5aH3UwxbaV3lxN9e5FhzeX/rnxW17A0=",
"ref": "refs/heads/Development",
"rev": "21bdbe569c959d06c02d9e492ba6c737bab92244",
"revCount": 100,
"rev": "a805e823d8006b9597af871f7ba1a18d9daaedad",
"revCount": 101,
"type": "git",
"url": "https://git.orion-technologies.io/blog/blog"
},
@ -150,11 +150,11 @@
]
},
"locked": {
"lastModified": 1727249977,
"narHash": "sha256-lAqOCDI4B6hA+t+KHSm/Go8hQF/Ob5sgXaIRtMAnMKw=",
"lastModified": 1727359191,
"narHash": "sha256-5PltTychnExFwzpEnY3WhOywaMV/M6NxYI/y3oXuUtw=",
"owner": "nix-community",
"repo": "disko",
"rev": "c1c472f4cd91e4b0703e02810a8c7ed30186b6fa",
"rev": "67dc29be3036cc888f0b9d4f0a788ee0f6768700",
"type": "github"
},
"original": {
@ -174,11 +174,11 @@
"nixpkgs-stable": "nixpkgs-stable"
},
"locked": {
"lastModified": 1727281458,
"narHash": "sha256-wp4a4+dDAjFYm5tI5BjjgcE4hdjpDcv5U3O+07xjwVc=",
"lastModified": 1727411519,
"narHash": "sha256-9xQF78yyNv/dkJ56HKVtJLRM6aoytIk6VPyNlR25Zyk=",
"owner": "nix-community",
"repo": "emacs-overlay",
"rev": "e81b6546fb597e6204bd6ef1bd0e6d35d498be20",
"rev": "a4ee09a79bdebef57ee7b1b74586c6d1f438541a",
"type": "github"
},
"original": {
@ -406,11 +406,11 @@
]
},
"locked": {
"lastModified": 1727246346,
"narHash": "sha256-TcUaKtya339Asu+g6KTJ8h7KiKcKXKp2V+At+7tksyY=",
"lastModified": 1727383923,
"narHash": "sha256-4/vacp3CwdGoPf8U4e/N8OsGYtO09WTcQK5FqYfJbKs=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "1e22ef1518fb175d762006f9cae7f6312b8caedb",
"rev": "ffe2d07e771580a005e675108212597e5b367d2d",
"type": "github"
},
"original": {
@ -479,11 +479,11 @@
"nixpkgs-regression": "nixpkgs-regression"
},
"locked": {
"lastModified": 1727264689,
"narHash": "sha256-SwPqM1ZvLsmbBXyGP0egysO/JQWQb9GhqgURt2PMKyk=",
"lastModified": 1727380702,
"narHash": "sha256-1YUAqvZc9YOUERyPiaOGYEg2fIf20+yIWGhzB0Ke6j8=",
"owner": "nixos",
"repo": "nix",
"rev": "6c37d815145369cbb9136f3aaa01f5fcd25d9db6",
"rev": "0ed67e5b7ee9ad8fae162e1b10b25d22ada2b1f3",
"type": "github"
},
"original": {
@ -526,11 +526,11 @@
},
"nixpkgs-master": {
"locked": {
"lastModified": 1727294711,
"narHash": "sha256-7G6JIC7Vb26C48oFmpwOr1OuOJK8YEJwF3w3yN7Byyc=",
"lastModified": 1727412098,
"narHash": "sha256-ujxF8U/dzaIeF5E9oG7INl4xC8pCjoxprTdtGoagjp0=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "c7412922a1d6acdc40250ba8e6460fd39c3fc2c7",
"rev": "f9c724d55b077d109a521f90736bfc4095ccd67d",
"type": "github"
},
"original": {
@ -557,11 +557,11 @@
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1727129439,
"narHash": "sha256-nPyrcFm6FSk7CxzVW4x2hu62aLDghNcv9dX6DF3dXw8=",
"lastModified": 1727264057,
"narHash": "sha256-KQPI8CTTnB9CrJ7LrmLC4VWbKZfljEPBXOFGZFRpxao=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "babc25a577c3310cce57c72d5bed70f4c3c3843a",
"rev": "759537f06e6999e141588ff1c9be7f3a5c060106",
"type": "github"
},
"original": {
@ -589,11 +589,11 @@
},
"nixpkgs_3": {
"locked": {
"lastModified": 1726937504,
"narHash": "sha256-bvGoiQBvponpZh8ClUcmJ6QnsNKw0EMrCQJARK3bI1c=",
"lastModified": 1727122398,
"narHash": "sha256-o8VBeCWHBxGd4kVMceIayf5GApqTavJbTa44Xcg5Rrk=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "9357f4f23713673f310988025d9dc261c20e70c6",
"rev": "30439d93eb8b19861ccbe3e581abf97bdc91b093",
"type": "github"
},
"original": {
@ -617,6 +617,7 @@
"nix": "nix",
"nixpkgs": "nixpkgs_3",
"nixpkgs-master": "nixpkgs-master",
"secrets": "secrets",
"wezterm": "wezterm"
}
},
@ -662,6 +663,24 @@
"type": "github"
}
},
"secrets": {
"flake": false,
"locked": {
"lastModified": 1727412130,
"narHash": "sha256-pifu78oIrAsnU8Iu51iXSPT331mJ6ehHy5iX/ZTQsSE=",
"ref": "refs/heads/main",
"rev": "8c078e598aeb9f4ead31cba2e8a62c7e77d75151",
"revCount": 1,
"submodules": true,
"type": "git",
"url": "file:secrets"
},
"original": {
"submodules": true,
"type": "git",
"url": "file:secrets"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,

View File

@ -39,6 +39,10 @@
inputs.nixpkgs.follows = "nixpkgs";
inputs.flake-utils.follows = "flake-utils";
};
secrets = {
url = "git+file:secrets?submodules=1";
flake = false;
};
};
outputs =
@ -200,7 +204,7 @@
inputs.disko.nixosModules.disko
{
config =
(import "${self}/secrets" {
(import "${inputs.secrets}" {
agenix = false;
inherit clib;
}).${hostname};
@ -228,7 +232,7 @@
inputs.disko.nixosModules.disko
{
config =
(import "${self}/secrets" {
(import "${inputs.secrets}" {
agenix = false;
inherit clib;
}).${hostname};

1
secrets Submodule

@ -0,0 +1 @@
Subproject commit 8c078e598aeb9f4ead31cba2e8a62c7e77d75151

View File

@ -1,61 +0,0 @@
{
agenix ? false,
clib ? import ../clib { },
}:
let
masterKeys = [
"age1yubikey1qfnj0k4mkzrn8ef5llwh2sv6hd7ckr0qml3n9hzdpz9c59ypvryhyst87k0"
"age1ur2lr3z6d2eftgxcalc6s5x9840ew9x43upl9k23wg0ugacrn5as4zl6sj"
];
hosts = {
luna =
let
secrets = "hosts/luna";
in
{
users-root-pw = "${secrets}/users-root-pw.age";
users-price-pw = "${secrets}/users-price-pw.age";
gitea-db-pass = "${secrets}/gitea-db-pass.age";
gitea-runner-token = "${secrets}/gitea-runner-token.age";
gh-ts-autotag-runner-token = "${secrets}/gh-ts-autotag-runner-token.age";
};
orion =
let
secrets = "hosts/orion";
in
{
users-root-pw = "${secrets}/users-root-pw.age";
users-price-pw = "${secrets}/users-price-pw.age";
};
};
in
if agenix then
(builtins.listToAttrs (
builtins.concatMap (
host:
let
hostSecrets = (builtins.getAttr host hosts);
in
(builtins.map (
hostSecretName:
let
secret = (builtins.getAttr hostSecretName hostSecrets);
in
{
name = builtins.toString secret;
value = {
publicKeys = [ (import ./../hosts/${host}/pubkey.nix) ] ++ masterKeys;
};
}
) (builtins.attrNames hostSecrets))
) (builtins.attrNames hosts)
))
else
(builtins.mapAttrs (
host: secrets:
(clib.recursiveMerge (
builtins.map (secretName: { age.secrets.${secretName}.file = ./${secrets.${secretName}}; }) (
builtins.attrNames hosts.${host}
)
))
) hosts)

View File

@ -1,14 +0,0 @@
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IFdvUU04QSA3d0F4
VUVXallDK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