mirror of
https://github.com/oddlama/nix-config.git
synced 2025-10-10 23:00:39 +02:00
feat: get myuser's username from repository secrets
This commit is contained in:
parent
32e346be56
commit
5bf0935eb2
2 changed files with 20 additions and 7 deletions
10
secrets/secrets.nix.age
Normal file
10
secrets/secrets.nix.age
Normal file
|
@ -0,0 +1,10 @@
|
|||
age-encryption.org/v1
|
||||
-> X25519 G4gcvnrT5F96VKuJKWCZnu3FaQl8Mw53cTfAw75HvDo
|
||||
aW5tQryfBWLjGAhxzds0tNgD2Q7+GbC19ev0LTmnAag
|
||||
-> piv-p256 xqSe8Q Ak7W7nWemREYSyuxsCGZq3anjmSBjZXxInYRjyxhlULw
|
||||
a4D3LWlMB8mROXAtHeVtt8WckgBdrRwD0y2hJt9qLKg
|
||||
-> \aR-grease 2J>j% 4M/Y^- x1`AZ_,W )YZ/;NT
|
||||
pWcsdkCVXg9tB54p3/YcZt8VGpH+5FdZCZM6xFDvXai0AED9V9AKMWK9jOfqCQYN
|
||||
RvhfpOVyL0r8
|
||||
--- GYfc2AZAGyiEdSaSfw/BdsMFVQrVCYLM0rDAUtk3k9E
|
||||
Ð[S©÷^}ð*ÞTϳ.ÍS"ÀÇÝôØH_ ¦zì˜iè”�`}¦,)‰x÷ƒ‹/;á”îÐtüw¢ïÖV‰¿þ
|
|
@ -2,15 +2,18 @@
|
|||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
secrets,
|
||||
...
|
||||
}:
|
||||
with lib; {
|
||||
users.groups.myuser.gid = config.users.users.myuser.uid;
|
||||
users.users.myuser = {
|
||||
with lib; let
|
||||
inherit (secrets) myuser;
|
||||
in {
|
||||
users.groups.${myuser}.gid = config.users.users.${myuser}.uid;
|
||||
users.users.${myuser} = {
|
||||
uid = 1000;
|
||||
hashedPassword = "$6$YogAnKRz8qW2Gz.I$chgMKKrpPAfV0WuGN6ChOgUJistpCzFsHOT6mhHyj07mwI1kSfDJvnMB13frMvkpv2aGpXHVH.yxk5fYHeeET/";
|
||||
createHome = true;
|
||||
group = "myuser";
|
||||
group = myuser;
|
||||
extraGroups =
|
||||
["wheel" "input" "video"]
|
||||
++ optionals config.sound.enable ["audio"];
|
||||
|
@ -18,7 +21,7 @@ with lib; {
|
|||
shell = pkgs.zsh;
|
||||
};
|
||||
|
||||
home-manager.users.myuser = {
|
||||
home-manager.users.${myuser} = {
|
||||
imports = [
|
||||
#impermanence.home-manager.impermanence
|
||||
../common
|
||||
|
@ -28,8 +31,8 @@ with lib; {
|
|||
];
|
||||
|
||||
home = {
|
||||
username = config.users.users.myuser.name;
|
||||
inherit (config.users.users.myuser) uid;
|
||||
username = config.users.users.${myuser}.name;
|
||||
inherit (config.users.users.${myuser}) uid;
|
||||
shellAliases = {
|
||||
p = "cd ~/projects";
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue