feat(machine, secrets): add qmk and vial, export gemini key
This commit is contained in:
parent
399e049775
commit
96321d4026
3 changed files with 51 additions and 31 deletions
|
@ -13,39 +13,41 @@ let
|
|||
inherit (cfg.paths) secrets;
|
||||
in
|
||||
{
|
||||
flake.modules.nixos.default =
|
||||
{ config, ... }:
|
||||
{
|
||||
imports = [ inputs.sops-nix.nixosModules.sops ];
|
||||
config = {
|
||||
sops = {
|
||||
age.sshKeyPaths = [
|
||||
"/persist${config.users.defaultUserHome}/${username}/.ssh/id_ed25519"
|
||||
];
|
||||
secrets."keys/gemini".sopsFile = secrets + "/keys.yaml";
|
||||
flake.modules = {
|
||||
nixos.default =
|
||||
{ config, ... }:
|
||||
{
|
||||
imports = [ inputs.sops-nix.nixosModules.sops ];
|
||||
config = {
|
||||
sops = {
|
||||
age.sshKeyPaths = [
|
||||
"/persist${config.users.defaultUserHome}/${username}/.ssh/id_ed25519"
|
||||
];
|
||||
secrets."keys/gemini".sopsFile = secrets + "/keys.yaml";
|
||||
};
|
||||
environment.shellInit = # sh
|
||||
''
|
||||
export GEMINI_API_KEY=$(sudo cat ${config.sops.secrets."keys/gemini".path})
|
||||
'';
|
||||
};
|
||||
environment.shellInit = # sh
|
||||
''
|
||||
export GEMINI_API_KEY=$(sudo cat ${config.sops.secrets."keys/gemini".path})
|
||||
'';
|
||||
};
|
||||
};
|
||||
flake.modules.darwin.default =
|
||||
{ config, ... }:
|
||||
{
|
||||
imports = [ inputs.sops-nix.darwinModules.sops ];
|
||||
config = {
|
||||
sops = {
|
||||
age.sshKeyPaths = [ "${config.users.users.${username}.home}/.ssh/id_ed25519" ];
|
||||
secrets."keys/gemini".sopsFile = secrets + "/keys.yaml";
|
||||
darwin.default =
|
||||
{ config, ... }:
|
||||
{
|
||||
imports = [ inputs.sops-nix.darwinModules.sops ];
|
||||
config = {
|
||||
sops = {
|
||||
age.sshKeyPaths = [ "${config.users.users.${username}.home}/.ssh/id_ed25519" ];
|
||||
secrets."keys/gemini".sopsFile = secrets + "/keys.yaml";
|
||||
};
|
||||
environment.shellInit = # sh
|
||||
''
|
||||
export GEMINI_API_KEY=$(sudo cat ${config.sops.secrets."keys/gemini".path})
|
||||
'';
|
||||
};
|
||||
environment.shellInit = # sh
|
||||
''
|
||||
export GEMINI_API_KEY=$(sudo cat ${config.sops.secrets."keys/gemini".path})
|
||||
'';
|
||||
};
|
||||
};
|
||||
flake.modules.homeManager.default.persistDirs = [ ".config/sops/age" ];
|
||||
homeManager.default.persistDirs = [ ".config/sops/age" ];
|
||||
};
|
||||
perSystem =
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue