Saltstack Official Linux Formula
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

network.sls 2.7KB

9 vuotta sitten
9 vuotta sitten
9 vuotta sitten
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. linux:
  2. system:
  3. enabled: true
  4. domain: ci.local
  5. name: linux.ci.local
  6. network:
  7. enabled: true
  8. hostname: linux
  9. fqdn: linux.ci.local
  10. network_manager: false
  11. #interface:
  12. #eth0:
  13. #enabled: true
  14. #type: eth
  15. #address: 192.168.0.102
  16. #netmask: 255.255.255.0
  17. #gateway: 192.168.0.1
  18. #name_servers:
  19. #- 8.8.8.8
  20. #- 8.8.4.4
  21. #mtu: 1500
  22. #vlan69:
  23. #enabled: true
  24. #type: vlan
  25. #use_interfaces:
  26. #- interface: ${linux:interface:eth0}
  27. dhclient:
  28. enabled: true
  29. backoff_cutoff: 15
  30. initial_interval: 10
  31. reboot: 10
  32. retry: 60
  33. select_timeout: 0
  34. timeout: 120
  35. send:
  36. - option: host-name
  37. declaration: "= gethostname()"
  38. supersede:
  39. - option: host-name
  40. declaration: linux
  41. - option: domain-name
  42. declaration: ci.local
  43. #- option: arp-cache-timeout
  44. # declaration: 20
  45. prepend:
  46. - option: domain-name-servers
  47. declaration:
  48. - 8.8.8.8
  49. - 8.8.4.4
  50. - option: domain-search
  51. declaration:
  52. - example.com
  53. - eng.example.com
  54. # ip or subnet to reject dhcp offer from
  55. reject:
  56. - 10.0.2.0/24
  57. request:
  58. - subnet-mask
  59. - broadcast-address
  60. - time-offset
  61. - routers
  62. - domain-name
  63. - domain-name-servers
  64. - domain-search
  65. - host-name
  66. - dhcp6.name-servers
  67. - dhcp6.domain-search
  68. - dhcp6.fqdn
  69. - dhcp6.sntp-servers
  70. - netbios-name-servers
  71. - netbios-scope
  72. - interface-mtu
  73. - rfc3442-classless-static-routes
  74. - ntp-servers
  75. require:
  76. - subnet-mask
  77. - domain-name-servers
  78. # if per interface configuration required add below
  79. # interface:
  80. # ens2:
  81. # initial_interval: 11
  82. # request:
  83. # - subnet-mask
  84. # - broadcast-address
  85. # reject:
  86. # - 10.0.3.0/24
  87. # ens3:
  88. # initial_interval: 12
  89. # reject:
  90. # - 10.0.4.0/24
  91. systemd:
  92. link:
  93. 10-iface-dmz:
  94. match:
  95. type: eth
  96. # MACAddress: c8:5b:7f:a5:1a:da
  97. # OriginalName: eth0
  98. link:
  99. name: dmz0
  100. netdev:
  101. 20-bridge:
  102. NetDev:
  103. Name: br0
  104. Kind: bridge
  105. 20-bridge-dmz:
  106. # test all lowercase
  107. match:
  108. name: dmz0
  109. network:
  110. description: bridge
  111. bridge: br-dmz0
  112. network:
  113. 40-dhcp:
  114. Match:
  115. Name: '*'
  116. Network:
  117. DHCP: yes