Skip to content

Instantly share code, notes, and snippets.

@acidprime
Created January 22, 2015 15:26
Show Gist options
  • Save acidprime/66648f4346218081b31f to your computer and use it in GitHub Desktop.
Save acidprime/66648f4346218081b31f to your computer and use it in GitHub Desktop.
Remove multiple hosts with augeas
augeas { 'remove_multi_hosts':
context => '/files/etc/hosts',
changes => [
"rm *[canonical = 'foo.bar.com']",
],
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment