power
This commit is contained in:
parent
4611e2bace
commit
2b60fa5807
|
@ -7,8 +7,7 @@
|
|||
}: let
|
||||
sshKeys = import ../../crypto/ssh-keys.nix;
|
||||
in {
|
||||
imports =
|
||||
[
|
||||
imports = [
|
||||
# Defaults
|
||||
./hardware-configuration.nix
|
||||
../../common/base.nix
|
||||
|
@ -65,6 +64,14 @@ boot.loader.systemd-boot.enable = lib.mkForce false;
|
|||
"/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;
|
||||
|
||||
services.tailscale.enable = true;
|
||||
|
@ -143,5 +150,4 @@ users.users.tasia.openssh.authorizedKeys.keys = [
|
|||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
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’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
config,
|
||||
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"];
|
||||
|
@ -13,8 +17,8 @@
|
|||
boot.kernelModules = [];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/e867382a-7ecb-4a93-bf7c-c972be061180";
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/e867382a-7ecb-4a93-bf7c-c972be061180";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@"];
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue