add remote container
This commit is contained in:
32
system-config/services/containers/nixos-remote/default.nix
Normal file
32
system-config/services/containers/nixos-remote/default.nix
Normal file
@@ -0,0 +1,32 @@
|
||||
{ config, lib, pkgs, ... }: {
|
||||
|
||||
options.sysconfig.opts.virtualization.nixos-remote.enable = lib.options.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.opts.virtualization.nixos-remote.enable {
|
||||
|
||||
containers.nixos-remote = {
|
||||
|
||||
ephemeral = true;
|
||||
autoStart = false;
|
||||
privateNetwork = true;
|
||||
hostAddress = "192.168.100.10";
|
||||
localAddress = "192.168.100.17";
|
||||
|
||||
extraFlags = [
|
||||
"-U"
|
||||
];
|
||||
|
||||
config = { config, lib, pkgs, ... }: {
|
||||
|
||||
users.users.nixos = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" ];
|
||||
initialPassword = "7567";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user