-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nixos/tmp: move /tmp options under boot.tmp #204534
Conversation
da973a4
to
d33740d
Compare
nixos/modules/system/boot/tmp.nix
Outdated
type = types.bool; | ||
default = false; | ||
description = lib.mdDoc '' | ||
Whether to delete all files in {file}`/tmp` during boot. | ||
''; | ||
}; | ||
|
||
boot.tmpOnTmpfs = mkOption { | ||
boot.tmp.onTmpfs = mkOption { | ||
type = types.bool; | ||
default = false; | ||
description = lib.mdDoc '' | ||
Whether to mount a tmpfs on {file}`/tmp` during boot. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we can use this opportunity to also inform about side effects, such as large builds (like the kernel) failing if there isn't enough space?
Last time I tried, a 16GB tmpfs wasn't enough space to build a kernel using Nix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you have a suggestion feel free to provide an improved text.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apart from my optional suggestion above, LGTM
nixos/modules/system/boot/tmp.nix
Outdated
type = types.bool; | ||
default = false; | ||
description = lib.mdDoc '' | ||
Whether to delete all files in {file}`/tmp` during boot. | ||
''; | ||
}; | ||
|
||
boot.tmpOnTmpfs = mkOption { | ||
boot.tmp.onTmpfs = mkOption { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion: boot.tmp.mountTmpfs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I forget to push that yesterday but I already renamed it to useTmpfs.
d33740d
to
a5d95ac
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…ad of `boot.tmpOnTmpfs` This change fixes the following warning: ``` trace: Obsolete option `boot.tmpOnTmpfs' is used. It was renamed to `boot.tmp.useTmpfs'. ``` This option was renamed in this PR: NixOS/nixpkgs#204534
211: fix(modules/service/nixos-init): Use `boot.tmp.useTmpfs` option instead of `boot.tmpOnTmpfs` r=roberth a=MartinNikov This change fixes the following warning: ``` trace: Obsolete option `boot.tmpOnTmpfs' is used. It was renamed to `boot.tmp.useTmpfs'. ``` This option was renamed in this PR: NixOS/nixpkgs#204534 Co-authored-by: MartinNikov <99672862+MartinNikov@users.noreply.github.com>
…ad of `boot.tmpOnTmpfs` This change fixes the following warning: ``` trace: Obsolete option `boot.tmpOnTmpfs' is used. It was renamed to `boot.tmp.useTmpfs'. ``` This option was renamed in this PR: NixOS/nixpkgs#204534
Open for suggestions for better names
Description of changes
Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)nixos/doc/manual/md-to-db.sh
to update generated release notes