New Flake Style + WSL + NixOnDroid
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
{ pkgs, host, lib, ... }:
|
||||
{ pkgs, hyper, lib, ... }:
|
||||
lib.mkIf (host != "NxACE")
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ config, pkgs, user, ... }:
|
||||
{ pkgs, hyper, ... }:
|
||||
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
@@ -12,7 +12,7 @@
|
||||
# vpnKitMaxPortIdleTime = 0;
|
||||
# };
|
||||
};
|
||||
users.users."${user}".extraGroups = [ "docker" ];
|
||||
users.users."${hyper.user}".extraGroups = [ "docker" ];
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ pkgs, lib, host, secrets, ... }:
|
||||
{ pkgs, hyper, secrets, ... }:
|
||||
{
|
||||
# sops.secrets = {
|
||||
# "wireless-networking.env" = {};
|
||||
@@ -9,7 +9,7 @@
|
||||
"1.1.1.1"
|
||||
"8.8.8.8"
|
||||
];
|
||||
hostName = host;
|
||||
hostName = hyper.host;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
};
|
||||
@@ -21,14 +21,4 @@
|
||||
8080
|
||||
];
|
||||
};
|
||||
environment.etc = {
|
||||
"ssl/certs/tuda-eduroam-root.crt".source = "${pkgs.cacert.unbundled}/etc/ssl/certs/T-TeleSec_GlobalRoot_Class_2:1.crt";
|
||||
};
|
||||
sops.secrets = {
|
||||
"eduroam/tuda_nmconnection" = {
|
||||
mode = "0600";
|
||||
owner = "root";
|
||||
path = "/etc/NetworkManager/system-connections/eduroam.nmconnection";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
{ host, secrets, ... }:
|
||||
{ hyper, secrets, ... }:
|
||||
|
||||
{
|
||||
environment.etc."ssh/ssh_host_ed25519_key.pub".text = if (host == "NxNORTH") then
|
||||
environment.etc."ssh/ssh_host_ed25519_key.pub".text = if (hyper.host == "NxNORTH") then
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIF1r5gUQPPS/dGB0SsvWtP6WdNWoxMwhhHRrqlO19cJt root@NxNORTH"
|
||||
else if ( host == "NxXPS" ) then
|
||||
else if ( hyper.host == "NxXPS" ) then
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPf+08+t8a0lY2+nR1mhIU3vuksStiJOlojJjzCwFk7r root@NxXPS"
|
||||
else
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBFfZpWVPlujsz3FklSVAM+tuYn4pzDSijhp5CeYNOZk root@NxACE";
|
||||
sops.secrets."ssh/${host}-ssh_host_ed25519_key" = {
|
||||
sops.secrets."ssh/${hyper.host}-ssh_host_ed25519_key" = {
|
||||
mode = "0600";
|
||||
path = "/etc/ssh/ssh_host_ed25519_key.shadow";
|
||||
};
|
||||
|
||||
13
system-modules/tuda.nix
Normal file
13
system-modules/tuda.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
environment.etc = {
|
||||
"ssl/certs/tuda-eduroam-root.crt".source = "${pkgs.cacert.unbundled}/etc/ssl/certs/T-TeleSec_GlobalRoot_Class_2:1.crt";
|
||||
};
|
||||
sops.secrets = {
|
||||
"eduroam/tuda_nmconnection" = {
|
||||
mode = "0600";
|
||||
owner = "root";
|
||||
path = "/etc/NetworkManager/system-connections/eduroam.nmconnection";
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
{ pkgs, user, ... }:
|
||||
|
||||
{ pkgs, hyper, ... }:
|
||||
{
|
||||
users.defaultUserShell = pkgs.bash; # if interactive, itll switch to fish
|
||||
|
||||
users.users."${user}" = {
|
||||
users.users."${hyper.user}" = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [
|
||||
# TODO: actually put the groups into the relevant files
|
||||
|
||||
Reference in New Issue
Block a user