mirror of
https://github.com/starr-dusT/dotfiles.git
synced 2025-02-18 10:47:31 -08:00
remove system folder and relocate modules
This commit is contained in:
parent
663b5cad56
commit
6fa1f92b1b
@ -42,10 +42,7 @@
|
||||
};
|
||||
services = {
|
||||
samba-client.enable = true;
|
||||
};
|
||||
system = {
|
||||
ssh.enable = true;
|
||||
terminal.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -49,6 +49,7 @@
|
||||
};
|
||||
programs = {
|
||||
beancount.enable = true;
|
||||
borg.enable = true;
|
||||
chezmoi.apply = true;
|
||||
kitty.enable = true;
|
||||
virt-manager.enable = true;
|
||||
@ -63,11 +64,7 @@
|
||||
};
|
||||
services = {
|
||||
samba-client.enable = true;
|
||||
};
|
||||
system = {
|
||||
backup.enable = true;
|
||||
ssh.enable = true;
|
||||
terminal.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -1,4 +1,10 @@
|
||||
{ ... }:
|
||||
{
|
||||
imports = [ ./desktop ./devel ./gaming ./programs ./system ./services ];
|
||||
imports = [
|
||||
./desktop
|
||||
./devel
|
||||
./gaming
|
||||
./programs
|
||||
./services
|
||||
];
|
||||
}
|
||||
|
@ -1,10 +1,15 @@
|
||||
{ config, lib, pkgs, user, ... }:
|
||||
|
||||
let cfg = config.modules.system.terminal;
|
||||
let cfg = config.modules.programs.base.terminal;
|
||||
in {
|
||||
options.modules.system.terminal.enable = lib.mkEnableOption "terminal";
|
||||
config = lib.mkIf cfg.enable {
|
||||
options.modules.programs.base.terminal = with lib; {
|
||||
enable = lib.mkOption {
|
||||
type = with types; bool;
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
environment.systemPackages = with pkgs; [
|
||||
killall # Command-line utility to terminate processes by name.
|
||||
pciutils # Utilities for inspecting and manipulating devices connected to the PCI bus.
|
@ -1,10 +1,9 @@
|
||||
{ config, pkgs, user, lib, ... }:
|
||||
|
||||
let cfg = config.modules.system.backup;
|
||||
let cfg = config.modules.programs.borg;
|
||||
in {
|
||||
options.modules.system.backup.enable = lib.mkEnableOption "backup";
|
||||
options.modules.programs.borg.enable = lib.mkEnableOption "borg";
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.borgmatic.enable = true;
|
||||
environment.systemPackages = with pkgs; [
|
||||
borgbackup # Deduplicating backup program
|
||||
tree
|
||||
@ -22,5 +21,6 @@ in {
|
||||
rm /tmp/docker_images
|
||||
'')
|
||||
];
|
||||
services.borgmatic.enable = true;
|
||||
};
|
||||
}
|
@ -1,7 +1,9 @@
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./base/terminal.nix
|
||||
./beancount.nix
|
||||
./borg.nix
|
||||
./chrome
|
||||
./firefox
|
||||
./git.nix
|
||||
|
@ -2,5 +2,6 @@
|
||||
{
|
||||
imports = [
|
||||
./samba-client.nix
|
||||
./ssh.nix
|
||||
];
|
||||
}
|
||||
|
15
provision/modules/services/ssh.nix
Normal file
15
provision/modules/services/ssh.nix
Normal file
@ -0,0 +1,15 @@
|
||||
{ config, lib, pkgs, user, ... }:
|
||||
|
||||
let cfg = config.modules.services.ssh;
|
||||
in {
|
||||
options.modules.services.ssh.enable = lib.mkEnableOption "ssh";
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.openssh.enable = true;
|
||||
services.pcscd.enable = true;
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
pinentryPackage = pkgs.pinentry-curses;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
};
|
||||
}
|
@ -1,4 +0,0 @@
|
||||
{ ... }:
|
||||
{
|
||||
imports = [ ./backup.nix ./ssh.nix ./terminal.nix ];
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
{ config, lib, pkgs, user, ... }:
|
||||
|
||||
let cfg = config.modules.system.ssh;
|
||||
in {
|
||||
options.modules.system.ssh.enable = lib.mkEnableOption "ssh";
|
||||
config = lib.mkIf cfg.enable {
|
||||
# Enable the OpenSSH daemon.
|
||||
services.openssh.enable = true;
|
||||
services.pcscd.enable = true;
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
pinentryPackage = pkgs.pinentry-curses;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
};
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user