mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-15 05:59:17 +03:00
Don't reboot a container when its configuration changes
Instead, just run "switch-to-configuration" inside the container.
This commit is contained in:
parent
511b86d22d
commit
ef8e0266a2
1 changed files with 8 additions and 0 deletions
|
@ -132,6 +132,14 @@ with pkgs.lib;
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
reloadIfChanged = true;
|
||||||
|
|
||||||
|
serviceConfig.ExecReload =
|
||||||
|
"${pkgs.bash}/bin/bash -c '"
|
||||||
|
+ "echo ${container.path}/bin/switch-to-configuration test "
|
||||||
|
+ "| ${pkgs.socat}/bin/socat unix:${container.root}/var/lib/root-shell.socket -'";
|
||||||
|
|
||||||
}) config.systemd.containers;
|
}) config.systemd.containers;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue