modules: rename user in the containers
This commit is contained in:
parent
f2038504b0
commit
6c0592d39b
3 changed files with 14 additions and 14 deletions
|
@ -11,7 +11,7 @@ let
|
|||
hostPackages = lib.flip map contPackages (p:
|
||||
let
|
||||
hostRunBrowser = pkgs.writeScript "cont-run-browser" ''
|
||||
sudo nixos-container run browsers -- su -l kira -c "$*"
|
||||
sudo nixos-container run browsers -- su -l jan -c "$*"
|
||||
'';
|
||||
|
||||
hostBrowserScript = pkgs.writeScriptBin "${p.meta.mainProgram}" ''
|
||||
|
@ -48,11 +48,7 @@ in
|
|||
bindMounts = lib.mkMerge [
|
||||
{
|
||||
"/tmp/.X11-unix" = { };
|
||||
"/etc/ssh/keys" = {
|
||||
isReadOnly = false;
|
||||
hostPath = "/persistent/per-machine/browsers/etc/ssh/keys";
|
||||
};
|
||||
"/home/kira/Downloads" = {
|
||||
"/home/jan/Downloads" = {
|
||||
isReadOnly = false;
|
||||
hostPath = "/home/jan/downloads/browser";
|
||||
};
|
||||
|
@ -64,11 +60,14 @@ in
|
|||
"/run/opengl-driver-32/lib" = { };
|
||||
})
|
||||
(lib.mkIf cfg.librewolf.enable {
|
||||
"/home/kira/.librewolf" = {
|
||||
"/home/jan/.librewolf" = {
|
||||
isReadOnly = false;
|
||||
hostPath = "/persistent/per-machine/browsers/home/kira/.librewolf";
|
||||
hostPath = "/persistent/per-machine/browsers/home/jan/.librewolf";
|
||||
};
|
||||
})
|
||||
(lib.mkIf config.local.programs.communication.telegram.enable {
|
||||
"/home/jan/downloads/telegram" = { };
|
||||
})
|
||||
];
|
||||
|
||||
config = { pkgs, ... }: {
|
||||
|
@ -79,9 +78,9 @@ in
|
|||
fontconfig = { inherit (config.fonts.fontconfig) defaultFonts; };
|
||||
};
|
||||
|
||||
users.users.kira = {
|
||||
users.users.jan = {
|
||||
isNormalUser = true;
|
||||
home = "/home/kira";
|
||||
home = "/home/jan";
|
||||
password = "hello";
|
||||
extraGroups = [ "pulse-access" ];
|
||||
packages = contPackages;
|
||||
|
|
|
@ -5,7 +5,7 @@ let
|
|||
cfg = config.local.programs.communication.skype;
|
||||
|
||||
hostRunPackage = pkgs.writeScript "cont-run" ''
|
||||
sudo nixos-container run skype -- su -l kira -c "$*"
|
||||
sudo nixos-container run skype -- su -l jan -c "$*"
|
||||
'';
|
||||
|
||||
hostPackageScript = pkgs.writeScriptBin "${cfg.package.meta.mainProgram}" ''
|
||||
|
@ -36,6 +36,7 @@ in
|
|||
bindMounts = lib.mkMerge [
|
||||
{
|
||||
"/tmp/.X11-unix" = { };
|
||||
"/home/jan/downloads/skype" = { isReadonly = false; };
|
||||
}
|
||||
(lib.mkIf config.hardware.graphics.enable {
|
||||
"/run/opengl-driver/lib" = { };
|
||||
|
@ -54,9 +55,9 @@ in
|
|||
fontconfig = { inherit (config.fonts.fontconfig) defaultFonts; };
|
||||
};
|
||||
|
||||
users.users.kira = {
|
||||
users.users.jan = {
|
||||
isNormalUser = true;
|
||||
home = "/home/kira";
|
||||
home = "/home/jan";
|
||||
password = "hello";
|
||||
extraGroups = [ "pulse-access" ];
|
||||
packages = [ cfg.package ];
|
||||
|
|
|
@ -59,7 +59,7 @@ in
|
|||
fontconfig = { inherit (config.fonts.fontconfig) defaultFonts; };
|
||||
};
|
||||
|
||||
users.users.kira = {
|
||||
users.users.jan = {
|
||||
isNormalUser = true;
|
||||
home = "/home/jan";
|
||||
password = "hello";
|
||||
|
|
Loading…
Reference in a new issue