mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-14 06:00:33 +03:00
Check and create /etc/NIXOS during activation
This commit is contained in:
parent
6fb85f6a03
commit
cba8b52942
1 changed files with 6 additions and 0 deletions
|
@ -138,3 +138,9 @@ foreach my $fn (@oldCopied) {
|
|||
# Rewrite /etc/.clean.
|
||||
close CLEAN;
|
||||
write_file("/etc/.clean", map { "$_\n" } @copied);
|
||||
|
||||
# Create /etc/NIXOS tag if not exists.
|
||||
# When /etc is not on a persistent filesystem, it will be wiped after reboot,
|
||||
# so we need to check and re-create it during activation.
|
||||
open TAG, ">>/etc/NIXOS";
|
||||
close TAG;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue