Watch
0
1
Fork
You've already forked nixos-configuration
0

Compare commits

...
Author SHA1 Message Date
müde
5bae4840e7 nix fmt ci yml
Some checks failed
build / build (muede-lpt2) (push) Has been cancelled
build / build (muede-pc2) (push) Has been cancelled
build / close-on-failure (push) Has been cancelled
2026-09-20 15:00:55 +02:00
müde
9fe9f12014 longer timeout for container stops 2026-09-20 15:00:55 +02:00
müde
5339721b50 throttle nix daemon on high mem 2026-09-20 15:00:55 +02:00
4 changed files with 36 additions and 12 deletions

View file

@ -3,7 +3,7 @@ name: build
on:
pull_request: {}
push:
branches: [ main ]
branches: [main]
jobs:
build:

View file

@ -2,11 +2,11 @@ name: flake update
on:
schedule:
- cron: '0 3 * * *'
- cron: "0 3 * * *"
workflow_dispatch:
inputs:
target:
description: 'Inputs to update'
description: "Inputs to update"
type: choice
default: all
options:

View file

@ -1,4 +1,9 @@
{ self, ... }:
{
config,
lib,
...
}:
{
config = {
boot.enableContainers = true;
@ -22,13 +27,25 @@
# };
# };
# # Global DefaultTimeoutStopSec is 10s (modern-desktop.nix), which kills systemd-nspawn
# # before it finishes halting, leaving cgroups busy and breaking restarts.
# systemd.services."container@damocles".serviceConfig = {
# TimeoutStopSec = "60s";
# # After a SIGKILL of nspawn, the kernel needs a moment to reap its cgroups.
# # Without this, the immediate restart attempt fails with "Device or resource busy".
# RestartSec = "5s";
# };
# Global DefaultTimeoutStopSec is 10s (modern-desktop.nix), which kills systemd-nspawn
# before it finishes halting, leaving cgroups busy and breaking restarts.
systemd.services =
let
# The imperative template plus every declarative container: nixos-containers
# generates each one as its own unit, so an override on "container@" alone
# would not reach them.
containerUnits = [
"container@"
]
++ map (name: "container@${name}") (lib.attrNames config.containers);
in
lib.genAttrs containerUnits (_: {
serviceConfig = {
TimeoutStopSec = "2min";
# After a SIGKILL of nspawn, the kernel needs a moment to reap its cgroups.
# Without this, the immediate restart attempt fails with "Device or resource busy".
RestartSec = "5s";
};
});
};
}

View file

@ -29,6 +29,13 @@
"i686-linux"
];
# Global default (nixosModules/distributed-builds.nix) is MemoryMax=90%,
# which isn't tight enough on this machine's 31GiB to avoid OOM.
systemd.services.nix-daemon.serviceConfig = {
MemoryHigh = "60%";
MemoryMax = lib.mkForce "80%";
};
services.xserver.xkb = {
# Configure keymap in X11
layout = "de";