Skip to content

Commit 0f2f463

Browse files
committed
resolved: onlyif snippet requires shell support
Fixes a problem (I) introduced in #276. Signed-off-by: Simon Deziel <[email protected]>
1 parent 4989f36 commit 0f2f463

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

manifests/resolved.pp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,10 @@
8787
# /etc/resolv.conf to something that might actually work on
8888
# reboot.
8989
exec { 'restore_resolv.conf_if_possible':
90-
command => 'cp --remove-destination -f /run/systemd/resolve/resolv.conf /etc/resolv.conf',
91-
onlyif => 'l="$(readlink /etc/resolv.conf)"; test "$l" = "/run/systemd/resolve/resolv.conf" || test "$l" = "/run/systemd/resolve/stub-resolv.conf',
92-
path => $facts['path'],
90+
command => 'cp --remove-destination -f /run/systemd/resolve/resolv.conf /etc/resolv.conf',
91+
onlyif => 'l="$(readlink /etc/resolv.conf)"; test "$l" = "/run/systemd/resolve/resolv.conf" || test "$l" = "/run/systemd/resolve/stub-resolv.conf',
92+
path => $facts['path'],
93+
provider => 'shell',
9394
}
9495
}
9596
}

0 commit comments

Comments
 (0)