This commit is contained in:
John Lancaster
2026-02-16 09:35:04 -06:00
parent c62545221c
commit 6dd5d2e171
4 changed files with 13 additions and 13 deletions

View File

@@ -2,15 +2,6 @@
{
imports = [
inputs.flake-file.flakeModules.dendritic
# inputs.flake-parts.flakeModules.modules
];
flake-file.description = "A dendritic setup.";
# flake-file.inputs = {
# flake-file.url = "github:vic/flake-file";
# flake-parts.url = "github:hercules-ci/flake-parts";
# nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
# systems.url = "github:nix-systems/default";
# };
systems = import inputs.systems;
}

View File

@@ -26,9 +26,11 @@ in
sops # This is necessary to make the sops binary available
ssh-to-age
(writeShellScriptBin "gen-age-key" ''
exec ${lib.getExe pkgs.ssh-to-age} -i ${config.sshIdentityFile} -private-key > ${ageKeyFile}
${lib.getExe pkgs.ssh-to-age} -i ${config.sshIdentityFile} -private-key > ${ageKeyFile}
echo -n "Created ${ageKeyFile}: "
echo $(show-age-key)
'')
(writeShellScriptBin "show-age-key" "exec ${lib.getExe pkgs.ssh-to-age} -i ${config.sshIdentityFile}.pub")
(writeShellScriptBin "show-age-key" "exec ${lib.getExe' pkgs.age "age-keygen"} -y ${ageKeyFile}")
(writeShellScriptBin "edit-secrets" "exec ${sopsBin} --config ${sopsConfigPath} ${sopsSecretsPath}")
(writeShellScriptBin "ls-secrets" "exec ${lib.getExe pkgs.eza} -alT --follow-symlinks ~/.config/sops-nix/secrets")
];
@@ -51,9 +53,9 @@ in
defaultSopsFormat = "yaml";
# Not sure any of these are necessary
age.sshKeyPaths = [ "${config.sshIdentityFile}" ];
# age.sshKeyPaths = [ "${config.sshIdentityFile}" ];
# age.keyFile = "${ageKeyFile}";
age.generateKey = true;
# age.generateKey = true;
# secrets."api/gmail_client_secret" = {
# path = "${config.xdg.configHome}/resticprofile/dendrite.txt";
@@ -64,6 +66,7 @@ in
content = ''
{
"installed": {
"bad: key,
"client_id": "499012320469-vtml6emu6bmujpsj9lud2b44jqu7h26j.apps.googleusercontent.com",
"project_id": "python-apis-423500",
"auth_uri": "https://accounts.google.com/o/oauth2/auth",