mirror of
https://github.com/Swarsel/.dotfiles.git
synced 2025-12-06 17:17:22 +01:00
feat: no more home-manager secrets on nixos hosts
This commit is contained in:
parent
803649e5cb
commit
70e5259192
7 changed files with 71 additions and 38 deletions
|
|
@ -8,7 +8,7 @@ in
|
|||
options.swarselmodules.mail = lib.mkEnableOption "mail settings";
|
||||
config = lib.mkIf config.swarselmodules.mail {
|
||||
|
||||
sops.secrets = lib.mkIf (!config.swarselsystems.isPublic) {
|
||||
sops.secrets = lib.mkIf (!config.swarselsystems.isPublic && !config.swarselsystems.isNixos) {
|
||||
address1-token = { path = "${xdgDir}/secrets/address1-token"; };
|
||||
address2-token = { path = "${xdgDir}/secrets/address2-token"; };
|
||||
address3-token = { path = "${xdgDir}/secrets/address3-token"; };
|
||||
|
|
@ -42,7 +42,7 @@ in
|
|||
address = address1;
|
||||
userName = address1;
|
||||
realName = fullName;
|
||||
passwordCommand = "cat ${config.sops.secrets.address1-token.path}";
|
||||
passwordCommand = "cat ${nixosConfig.sops.secrets.address1-token.path}";
|
||||
gpg = {
|
||||
key = "0x76FD3810215AE097";
|
||||
signByDefault = true;
|
||||
|
|
@ -74,7 +74,7 @@ in
|
|||
address = address4;
|
||||
userName = address4-user;
|
||||
realName = fullName;
|
||||
passwordCommand = "cat ${config.sops.secrets.address4-token.path}";
|
||||
passwordCommand = "cat ${nixosConfig.sops.secrets.address4-token.path}";
|
||||
smtp = {
|
||||
host = address4-host;
|
||||
port = 587;
|
||||
|
|
@ -97,7 +97,7 @@ in
|
|||
address = address2;
|
||||
userName = address2;
|
||||
realName = address2-name;
|
||||
passwordCommand = "cat ${config.sops.secrets.address2-token.path}";
|
||||
passwordCommand = "cat ${nixosConfig.sops.secrets.address2-token.path}";
|
||||
imap.host = "imap.gmail.com";
|
||||
smtp.host = "smtp.gmail.com";
|
||||
msmtp.enable = true;
|
||||
|
|
@ -124,7 +124,7 @@ in
|
|||
address = address3;
|
||||
userName = address3;
|
||||
realName = address3-name;
|
||||
passwordCommand = "cat ${config.sops.secrets.address3-token.path}";
|
||||
passwordCommand = "cat ${nixosConfig.sops.secrets.address3-token.path}";
|
||||
imap.host = "imap.gmail.com";
|
||||
smtp.host = "smtp.gmail.com";
|
||||
msmtp.enable = true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue