Fix rebooting containers where resolv.conf is a symlink
commit4106a3b74efa1631e28fc623f99468ff11f3ac36
authorLane Seppala <git@seppa.la>
dateFri 27 Feb 2015, 10:27 (12 years ago)
parentb6f2634
nixos/modules/virtualisation/containers.nix+1−1
@@ -212,7 +212,7 @@ in
212212 "/nix/var/nix/profiles/per-container/$INSTANCE" \
213213 "/nix/var/nix/gcroots/per-container/$INSTANCE"
214214
215− cp -f /etc/resolv.conf "$root/etc/resolv.conf"
215+ cp --remove-destination /etc/resolv.conf "$root/etc/resolv.conf"
216216
217217 if [ "$PRIVATE_NETWORK" = 1 ]; then
218218 extraFlags+=" --network-veth"