power
This commit is contained in:
parent
4611e2bace
commit
2b60fa5807
|
@ -7,8 +7,7 @@
|
||||||
}: let
|
}: let
|
||||||
sshKeys = import ../../crypto/ssh-keys.nix;
|
sshKeys = import ../../crypto/ssh-keys.nix;
|
||||||
in {
|
in {
|
||||||
imports =
|
imports = [
|
||||||
[
|
|
||||||
# Defaults
|
# Defaults
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
../../common/base.nix
|
../../common/base.nix
|
||||||
|
@ -65,6 +64,14 @@ boot.loader.systemd-boot.enable = lib.mkForce false;
|
||||||
"/crypto_keyfile.bin" = null;
|
"/crypto_keyfile.bin" = null;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.logind.extraConfig = ''
|
||||||
|
# don’t shutdown when power button is short-pressed
|
||||||
|
HandleLidSwitch=ignore
|
||||||
|
HandleLidSwitchExternalPower=ignore
|
||||||
|
HandleLidSwitchDocked=ignore
|
||||||
|
'';
|
||||||
|
|
||||||
|
|
||||||
boot.loader.grub.enableCryptodisk = true;
|
boot.loader.grub.enableCryptodisk = true;
|
||||||
|
|
||||||
services.tailscale.enable = true;
|
services.tailscale.enable = true;
|
||||||
|
@ -143,5 +150,4 @@ users.users.tasia.openssh.authorizedKeys.keys = [
|
||||||
# Before changing this value read the documentation for this option
|
# Before changing this value read the documentation for this option
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = "23.11"; # Did you read the comment?
|
system.stateVersion = "23.11"; # Did you read the comment?
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,15 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
config,
|
||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
lib,
|
||||||
|
pkgs,
|
||||||
|
modulesPath,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
(modulesPath + "/installer/scan/not-detected.nix")
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["uhci_hcd" "ehci_pci" "ahci" "firewire_ohci" "usbhid" "usb_storage" "sd_mod" "sr_mod" "sdhci_pci"];
|
boot.initrd.availableKernelModules = ["uhci_hcd" "ehci_pci" "ahci" "firewire_ohci" "usbhid" "usb_storage" "sd_mod" "sr_mod" "sdhci_pci"];
|
||||||
|
@ -13,8 +17,8 @@
|
||||||
boot.kernelModules = [];
|
boot.kernelModules = [];
|
||||||
boot.extraModulePackages = [];
|
boot.extraModulePackages = [];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" = {
|
||||||
{ device = "/dev/disk/by-uuid/e867382a-7ecb-4a93-bf7c-c972be061180";
|
device = "/dev/disk/by-uuid/e867382a-7ecb-4a93-bf7c-c972be061180";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=@"];
|
options = ["subvol=@"];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue