···270270271271- `services.nginx` gained a `defaultListen` option at server-level with support for PROXY protocol listeners, also `proxyProtocol` is now exposed in `services.nginx.virtualHosts.<name>.listen` option. It is now possible to run PROXY listeners and non-PROXY listeners at a server-level, see [#213510](https://github.com/NixOS/nixpkgs/pull/213510/) for more details.
272272273273-- `generic-extlinux-compatible` bootloader (and raspberry pi with uboot) supports appending secrets to the initramfs
274274-275273- `services.restic.backups` now adds wrapper scripts to your system path, which set the same environment variables as the service, so restic operations can easly be run from the command line. This behavior can be disabled by setting `createWrapper` to `false`, per backup configuration.
276274277275- `services.prometheus.exporters` has a new exporter to monitor electrical power consumption based on PowercapRAPL sensor called [Scaphandre](https://github.com/hubblo-org/scaphandre), see [#239803](https://github.com/NixOS/nixpkgs/pull/239803) for more details.
···7070addEntry() {
7171 local path=$(readlink -f "$1")
7272 local tag="$2" # Generation number or 'default'
7373- local current="$3" # whether this is the current/latest generation
74737574 if ! test -e $path/kernel -a -e $path/initrd; then
7675 return
7776 fi
78777979- if test -e "$path/append-initrd-secrets"; then
8080- local initrd="$target/nixos/$(basename "$path")-initramfs-with-secrets"
8181- cp $(readlink -f "$path/initrd") "$initrd"
8282- chmod 600 "${initrd}"
8383- chown 0:0 "${initrd}"
8484- filesCopied[$initrd]=1
8585-8686- "$path/append-initrd-secrets" "$initrd" || if test "${current}" = "1"; then
8787- echo "failed to create initrd secrets for the current generation." >&2
8888- echo "are your \`boot.initrd.secrets\` still in place?" >&2
8989- exit 1
9090- else
9191- echo "warning: failed to create initrd secrets for \"$path\", an older generation" >&2
9292- echo "note: this is normal after having removed or renamed a file in \`boot.initrd.secrets\`" >&2
9393- fi
9494- else
9595- copyToKernelsDir "$path/initrd"; initrd=$result
9696- fi
9797-9878 copyToKernelsDir "$path/kernel"; kernel=$result
9999-7979+ copyToKernelsDir "$path/initrd"; initrd=$result
10080 dtbDir=$(readlink -m "$path/dtbs")
10181 if [ -e "$dtbDir" ]; then
10282 copyToKernelsDir "$dtbDir"; dtbs=$result
···150130TIMEOUT $timeout
151131EOF
152132153153-addEntry $default default 1 >> $tmpFile
133133+addEntry $default default >> $tmpFile
154134155135if [ "$numGenerations" -gt 0 ]; then
156136 # Add up to $numGenerations generations of the system profile to the menu,
157137 # in reverse (most recent to least recent) order.
158158- current=1
159138 for generation in $(
160139 (cd /nix/var/nix/profiles && ls -d system-*-link) \
161140 | sed 's/system-\([0-9]\+\)-link/\1/' \
162141 | sort -n -r \
163142 | head -n $numGenerations); do
164143 link=/nix/var/nix/profiles/system-$generation-link
165165- addEntry $link $generation $current
166166- current=0
144144+ addEntry $link $generation
167145 done >> $tmpFile
168146fi
169147
···610610 path the secret should have inside the initrd, the value
611611 is the path it should be copied from (or null for the same
612612 path inside and out).
613613-614614- The loader `generic-extlinux-compatible` supports this. Because
615615- it is not well know how different implementations react to
616616- concatenated cpio archives, this is disabled by default. It can be
617617- enabled by setting {option}`boot.loader.supportsInitrdSecrets`
618618- to true. If this works for you, please report your findings at
619619- https://github.com/NixOS/nixpkgs/issues/247145 .
620613 '';
621614 example = literalExpression
622615 ''