Advertisement
zamotivator

Untitled

Jan 5th, 2014
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. root@salt-master:/srv/salt# cat top.sls
  2. base:
  3. '*.vps':
  4. - dns
  5. root@salt-master:/srv/salt# cat dns.sls
  6. include:
  7. - resolver
  8. extend:
  9. /etc/resolv.conf:
  10. file.managed:
  11. - context:
  12. searchpath: local.oleg.sh
  13. nameservers:
  14. - 10.10.10.196
  15. - 8.8.8.8
  16. root@salt-master:/srv/salt# salt '*' state.highstate
  17. proxy.vps:
  18. ----------
  19. State: - file
  20. Name: /etc/resolv.conf
  21. Function: managed
  22. Result: True
  23. Comment: File /etc/resolv.conf updated
  24. Changes: diff: ---
  25. +++
  26. @@ -1 +1,3 @@
  27. -
  28. +search local.oleg.sh
  29. +nameserver 10.10.10.196
  30. +nameserver 8.8.8.8
  31.  
  32. mode: 644
  33.  
  34.  
  35. Summary
  36. ------------
  37. Succeeded: 1
  38. Failed: 0
  39. ------------
  40. Total: 1
  41. root@salt-master:/srv/salt#
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement