1
1
Fork 0
nixos-configs/machine/backyard/default.nix

59 lines
1.5 KiB
Nix
Raw Normal View History

2024-04-13 04:50:53 +00:00
{ config, pkgs, ... }:
2023-08-02 00:13:35 +00:00
{
imports = [
./hardware-configuration.nix
2023-10-22 20:56:06 +00:00
./jellyfin.nix
];
2023-08-02 00:13:35 +00:00
2023-10-20 03:23:49 +00:00
boot.loader.grub = {
enable = true;
device = "/dev/sda";
};
2023-08-02 00:13:35 +00:00
2023-08-02 01:59:06 +00:00
beatific.hostName = "backyard";
beatific.defaults.tvbSync = false;
2023-08-02 00:13:35 +00:00
# Enable networking
networking.networkmanager.enable = true;
2023-08-02 15:18:26 +00:00
users.users.tvb.extraGroups = [ "networkmanager" ];
2023-08-02 00:13:35 +00:00
2023-08-02 15:39:25 +00:00
networking.firewall = {
2024-04-13 04:50:53 +00:00
enable = false;
};
#
users.users.guest = {
group = "guest";
description = "gueSSHtbook sshd user";
};
users.groups.guest = {};
systemd.services.guesshd = let
nssModulesPath = config.system.nssModules.path;
in {
enable = false;
description = "gueSSHtbook SSH daemon";
wantedBy = "multi-user.target";
after = [ "network.target" ];
stopIfChanged = false;
path = [ config.programs.ssh.package pkgs.gawk ];
environment.LD_LIBRARY_PATH = nssModulesPath;
#restartTriggers = [ config path goes here ];
# need keys to exist, see prestart in sshd.nix
serviceConfig = {
ExecStart = "${config.programs.ssh.package}/bin/sshd -D -f /path/to/config";
KillMode = "process";
Restart = "always";
Type = "simple";
2023-08-02 15:39:25 +00:00
};
2024-04-13 04:50:53 +00:00
networking.firewall.allowedTCPPorts = [ 2345 ];
#
2023-08-02 00:13:35 +00:00
2023-08-02 15:39:25 +00:00
# This value governs how some stateful data, like databases, are handled
# across different versions of NixOS. This should not be changed to a new
# release unless the sysadmin has determined that no services would be
# adversely affected by changing this.
system.stateVersion = "23.05";
2023-08-02 00:13:35 +00:00
}