!XLCFfvFhUkYwOMLbVx:nixos.org

agenix

374 Members
age-encrypted secrets for NixOS https://github.com/ryantm/agenix/97 Servers

Load older messages


SenderMessageTime
9 Mar 2023
@jayhenks:matrix.orgjayhenksYeah because I saw it was only updated 5 days ago on github21:59:07
@jayhenks:matrix.orgjayhenks * Yeah because I saw it was only updated 5 days ago on github (commit)21:59:52
10 Mar 2023
@whentze:matrix.orgWanja HentzeFrom personal experience I can attest that the maintainers respond quickly and are open to contributions :)10:10:36
@kranzes:matrix.orgIlan Joselevich (Kranzes)
In reply to @jayhenks:matrix.org
Yeah because I saw it was only updated 5 days ago on github (commit)
Last commit is not a measure of maintenance
14:22:44
@whentze:matrix.orgWanja Hentzealso, 5 days ago is really recent 🤔 I consider anything within a few months "recent changes"14:54:23
@jayhenks:matrix.orgjayhenksDoes agenix offer support for home manager?15:40:55
@cole-h:matrix.orgcole-hNo(t yet), see https://github.com/ryantm/agenix/issues/50 and https://github.com/ryantm/agenix/pull/109.15:41:38
@ryantm:matrix.orgryantmSupporting home manager confuses me.15:43:14
@ryantm:matrix.orgryantmEveryone keeps asking for it but it seems like a worthless thing.15:43:38
@ryantm:matrix.orgryantmIf you are using it with NixOS, you can already use the agenix module at the NixOS level. If you are using it at the user level, it doesn't provide any security.15:46:38
@jayhenks:matrix.orgjayhenksWhat would a home manager module mean? That I can use secrets inside home manager? Is that not possible already?15:49:16
@jayhenks:matrix.orgjayhenks Maybe I do not get something here 15:49:28
@ryantm:matrix.orgryantmThe only use case I understand is someone wants to publish their home manager config and doesn't want to share the secrets. Maybe that's enough to justify supporting it. I don't want to give people a false sense of security though...16:00:19
@dandellion:dodsorf.asDandellion
In reply to @ryantm:matrix.org
If you are using it with NixOS, you can already use the agenix module at the NixOS level. If you are using it at the user level, it doesn't provide any security.
why wouldnt it provide any security?
16:02:02
@ryantm:matrix.orgryantmThe user's clear text, encrypted secrets, and private key would all be in the same home directory.16:03:47
@dandellion:dodsorf.asDandellionowned by the user and not in the nix store though16:04:40
@ryantm:matrix.orgryantmYeah good point! I think I get it now.16:04:58
@jayhenks:matrix.orgjayhenks
In reply to @dandellion:dodsorf.as
owned by the user and not in the nix store though
But why would you want that
16:34:36
@jayhenks:matrix.orgjayhenks I do Not really get it 16:34:44
@dandellion:dodsorf.asDandellionFor the same reasons as you want it for the system16:44:52
@dandellion:dodsorf.asDandellionI don't understand what's different16:45:06
@jayhenks:matrix.orgjayhenks
In reply to @dandellion:dodsorf.as
I don't understand what's different
So it is just impossible to use agenix’s config.path in home manager to point to an encrypted file?
17:18:00
@peter-lustig:matrix.orgpeter-lustig joined the room.21:38:30
@peter-lustig:matrix.orgpeter-lustig

Hello. How could I represent the following secrets for firefox-syncserver with agenix?

      secrets = builtins.toFile "sync-secrets" ''
        SYNC_MASTER_SECRET=this-secret-is-actually-leaked-to-/nix/store
      '';

Do I just write SYNC_MASTER_SECRET=something in the agenix file?

21:39:41
@peter-lustig:matrix.orgpeter-lustig *

Hello. How could I represent the following secrets for firefox-syncserver with agenix?

      secrets = builtins.toFile "sync-secrets" ''
        SYNC_MASTER_SECRET=this-secret-is-actually-leaked-to-/nix/store
      '';

Do I just write SYNC_MASTER_SECRET=something in the .age file?

21:40:02
@cole-h:matrix.orgcole-hIf firefox-syncserver accepts a path to a file with that, yeah that would work.21:41:30
@cole-h:matrix.orgcole-h * If firefox-syncserver accepts a path to a file with those contents, yeah that would work.21:41:36
@peter-lustig:matrix.orgpeter-lustig
In reply to @cole-h:matrix.org
If firefox-syncserver accepts a path to a file with those contents, yeah that would work.

Looks like it takes a path:

Description
A file containing the various secrets. Should be in the format expected by systemd’s EnvironmentFile directory. Two secrets are currently available: SYNC_MASTER_SECRET and SYNC_TOKENSERVER__FXA_METRICS_HASH_SECRET.

Type
path
21:42:31
@cole-h:matrix.orgcole-h Then yeah, that should work. Just point it to config.age.secrets.<firefox-syncserver-server>.path 21:44:48
@peter-lustig:matrix.orgpeter-lustig
In reply to @cole-h:matrix.org
Then yeah, that should work. Just point it to config.age.secrets.<firefox-syncserver-server>.path

This should work, right?

      secrets = builtins.toFile "sync-secrets" config.age.secrets.mainserver-firefox-syncserver-secrets.age;

Modified the example config in the manual:

https://nixos.org/manual/nixos/unstable/index.html#module-services-firefox-syncserver-quickstart

21:46:05

Show newer messages


Back to Room ListRoom Version: 6