some server changes
This commit is contained in:
parent
6b7325b8d0
commit
2899c3f4fc
@ -29,10 +29,5 @@
|
|||||||
deviceSpecific.wireguard.enable = false;
|
deviceSpecific.wireguard.enable = false;
|
||||||
|
|
||||||
boot.cleanTmpDir = true;
|
boot.cleanTmpDir = true;
|
||||||
networking.hostName = "matrix-vm-instance";
|
# networking.hostName = lib.mkForce "Oracle-Cloud";
|
||||||
networking.firewall.allowPing = true;
|
|
||||||
services.openssh.enable = true;
|
|
||||||
users.users.root.openssh.authorizedKeys.keys = [
|
|
||||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC1OdiD3T30dTTVtwDjiVEQ+Dd9P92/4rI60x1xYtr6P75UYZF7eIO6FrxH8FAeSH6N10YsdTK1NPRDj5bsbLDB7d4D4YewPw+tnl3Qnp/04k+/+gpSFhVyUwKWvSTgU34NZFiwdHLuefYkHdAmDBhUhWC+28DyWSPn2LLTHhGRBOaNG39ur/1vaIuJb00vbzA/HWQmIYIByd51gjQkgC+SxIlYb13Q/L6SqHCZ8RUzJyS9bGM9Imw5T7V7SVC2FRjOt6NUm8AVVw06yRgtjXipEYA9GE+Rp69+MNmKr2OxR//KWyQb/SCfQyIWrBn0ee266XukOFuC4bpp50TjTEXx oracle_cloud"
|
|
||||||
];
|
|
||||||
}
|
}
|
||||||
|
@ -36,10 +36,10 @@ with types; {
|
|||||||
default =
|
default =
|
||||||
!isNull (builtins.match ".*VM" config.networking.hostName);
|
!isNull (builtins.match ".*VM" config.networking.hostName);
|
||||||
};
|
};
|
||||||
isCloud = mkOption {
|
isServer = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
default =
|
default =
|
||||||
!isNull (builtins.match ".*Cloud" config.networking.hostName);
|
!isNull (builtins.match ".*(Cloud|Server)" config.networking.hostName);
|
||||||
};
|
};
|
||||||
isISO = mkOption {
|
isISO = mkOption {
|
||||||
type = bool;
|
type = bool;
|
||||||
|
@ -30,7 +30,13 @@ with config.deviceSpecific;
|
|||||||
};
|
};
|
||||||
userControlled.enable = true;
|
userControlled.enable = true;
|
||||||
};
|
};
|
||||||
firewall.enable = false;
|
|
||||||
|
firewall = {
|
||||||
|
enable = true;
|
||||||
|
allowPing = true;
|
||||||
|
allowedTCPPorts = lib.mkIf isServer [ 22 80 443 13748 ];
|
||||||
|
};
|
||||||
|
|
||||||
usePredictableInterfaceNames = true;
|
usePredictableInterfaceNames = true;
|
||||||
hostName = config.device;
|
hostName = config.device;
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{ pkgs, config, lib, ... }: {
|
{ pkgs, config, lib, ... }:
|
||||||
|
with config.deviceSpecific; {
|
||||||
i18n.defaultLocale = "en_GB.UTF-8";
|
i18n.defaultLocale = "en_GB.UTF-8";
|
||||||
|
|
||||||
console.font = "cyr-sun16";
|
console.font = "cyr-sun16";
|
||||||
@ -11,9 +11,9 @@
|
|||||||
LANG = lib.mkForce "en_GB.UTF-8";
|
LANG = lib.mkForce "en_GB.UTF-8";
|
||||||
};
|
};
|
||||||
|
|
||||||
time.timeZone = lib.mkIf (!config.deviceSpecific.isCloud) "Europe/Moscow";
|
time.timeZone = lib.mkIf (!isServer) "Europe/Moscow";
|
||||||
|
|
||||||
location = lib.mkIf (!config.deviceSpecific.isCloud) {
|
location = lib.mkIf (!isServer) {
|
||||||
provider = "manual";
|
provider = "manual";
|
||||||
latitude = 48.78583;
|
latitude = 48.78583;
|
||||||
longitude = 44.77973;
|
longitude = 44.77973;
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
{ inputs, ... }: {
|
{ inputs, ... }: {
|
||||||
imports = with inputs.self.nixosModules; with inputs.self.nixosProfiles; [
|
imports = with inputs.self.nixosModules; with inputs.self.nixosProfiles; [
|
||||||
inputs.home-manager.nixosModules.home-manager
|
inputs.home-manager.nixosModules.home-manager
|
||||||
inputs.base16.hmModule
|
|
||||||
|
|
||||||
applications
|
applications
|
||||||
devices
|
devices
|
||||||
@ -9,19 +8,16 @@
|
|||||||
gpg
|
gpg
|
||||||
locale
|
locale
|
||||||
misc
|
misc
|
||||||
|
network
|
||||||
nix
|
nix
|
||||||
overlay
|
overlay
|
||||||
secrets
|
secrets
|
||||||
secrets-envsubst
|
secrets-envsubst
|
||||||
security
|
security
|
||||||
themes
|
|
||||||
ssh
|
ssh
|
||||||
xdg
|
xdg
|
||||||
zsh
|
zsh
|
||||||
|
|
||||||
kitty
|
|
||||||
|
|
||||||
direnv
|
direnv
|
||||||
fonts
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user