Initial NixOS infra flake skeleton
This commit is contained in:
commit
9383d615d7
9 changed files with 267 additions and 0 deletions
31
modules/common.nix
Normal file
31
modules/common.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
# Basic sane defaults
|
||||
time.timeZone = "Europe/Stockholm";
|
||||
|
||||
# SSH access (you’ll tweak users later)
|
||||
services.openssh.enable = true;
|
||||
services.openssh.settings = {
|
||||
PasswordAuthentication = false;
|
||||
KbdInteractiveAuthentication = false;
|
||||
PermitRootLogin = "no";
|
||||
};
|
||||
|
||||
# Helpful tools on the server
|
||||
environment.systemPackages = with pkgs; [
|
||||
git
|
||||
curl
|
||||
jq
|
||||
vim
|
||||
];
|
||||
|
||||
# Firewall on by default
|
||||
networking.firewall.enable = true;
|
||||
|
||||
# Nix settings (good defaults)
|
||||
nix.settings = {
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
auto-optimise-store = true;
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue