New Saltstack Salt 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.

README.rst 5.9KB

9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277
  1. ====
  2. Salt
  3. ====
  4. Salt is a new approach to infrastructure management. Easy enough to get running in minutes, scalable enough to manage tens of thousands of servers, and fast enough to communicate with them in seconds.
  5. Salt delivers a dynamic communication bus for infrastructures that can be used for orchestration, remote execution, configuration management and much more.
  6. Sample pillars
  7. ==============
  8. Salt master
  9. -----------
  10. Salt master with base production environment and pillar tree as metadata backend
  11. .. literalinclude:: tests/pillar/master_single_pillar.sls
  12. :language: yaml
  13. Salt master with reclass ENC as metadata backend
  14. .. literalinclude:: tests/pillar/master_single_reclass.sls
  15. :language: yaml
  16. Salt master with API
  17. .. literalinclude:: tests/pillar/master_api.sls
  18. :language: yaml
  19. Salt master with defined user ACLs
  20. .. literalinclude:: tests/pillar/master_acl.sls
  21. :language: yaml
  22. Salt master with preset minions
  23. .. code-block:: yaml
  24. salt:
  25. master:
  26. enabled: true
  27. minions:
  28. - name: 'node1.system.location.domain.com'
  29. Salt master with alternative installation source and version (optional) - pip
  30. .. code-block:: yaml
  31. salt:
  32. master:
  33. enabled: true
  34. ...
  35. source:
  36. engine: pip
  37. version: 2016.3.0rc2
  38. Salt master with specified formula to install through apt-get
  39. .. code-block:: yaml
  40. salt:
  41. master:
  42. enabled: true
  43. ...
  44. environment:
  45. prd:
  46. keysone:
  47. source: pkg
  48. name: salt-formula-keystone
  49. Clone master branch of keystone formula as local feature branch
  50. .. code-block:: yaml
  51. salt:
  52. master:
  53. enabled: true
  54. ...
  55. environment:
  56. dev:
  57. formula:
  58. keystone:
  59. source: git
  60. address: git@github.com:openstack/salt-formula-keystone.git
  61. revision: master
  62. branch: feature
  63. Salt master with specified formula refs (for example for Gerrit review)
  64. .. code-block:: yaml
  65. salt:
  66. master:
  67. enabled: true
  68. ...
  69. environment:
  70. dev:
  71. formula:
  72. keystone:
  73. source: git
  74. address: https://git.openstack.org/openstack/salt-formula-keystone
  75. revision: refs/changes/56/123456/1
  76. Salt syndic: Master of masters
  77. .. code-block:: yaml
  78. salt:
  79. master:
  80. enabled: true
  81. order_masters: True
  82. Salt syndic: Lower master
  83. .. code-block:: yaml
  84. salt:
  85. syndic:
  86. enabled: true
  87. master:
  88. host: master-of-master-host
  89. timeout: 5
  90. Salt master with custom handlers
  91. .. code-block:: yaml
  92. salt:
  93. master:
  94. enabled: true
  95. handler:
  96. handler01:
  97. engine: udp
  98. bind:
  99. host: 127.0.0.1
  100. port: 9999
  101. minion:
  102. handler:
  103. handler01:
  104. engine: udp
  105. bind:
  106. host: 127.0.0.1
  107. port: 9999
  108. handler02:
  109. engine: zmq
  110. bind:
  111. host: 127.0.0.1
  112. port: 9999
  113. Salt master peer for remote certificate sign.
  114. .. code-block:: yaml
  115. salt:
  116. master:
  117. peer:
  118. ".*":
  119. - x509.sign_remote_certificate
  120. Salt SSH
  121. --------
  122. Salt SSH with sudoer using key
  123. .. literalinclude:: tests/pillar/master_ssh_minion_key.sls
  124. :language: yaml
  125. Salt SSH with sudoer using password
  126. .. literalinclude:: tests/pillar/master_ssh_minion_password.sls
  127. :language: yaml
  128. Salt SSH with root using password
  129. .. literalinclude:: tests/pillar/master_ssh_minion_root.sls
  130. :language: yaml
  131. Salt minion
  132. -----------
  133. Simplest Salt minion setup with central configuration node
  134. .. code-block:: yaml
  135. .. literalinclude:: tests/pillar/minion_master.sls
  136. :language: yaml
  137. Multi-master Salt minion setup
  138. .. literalinclude:: tests/pillar/minion_multi_master.sls
  139. :language: yaml
  140. Salt minion with salt mine options
  141. .. literalinclude:: tests/pillar/minion_mine.sls
  142. :language: yaml
  143. Salt minion with graphing dependencies
  144. .. literalinclude:: tests/pillar/minion_graph.sls
  145. :language: yaml
  146. PKI CA
  147. ~~~~~~
  148. Salt minion with PKI CA
  149. .. literalinclude:: tests/pillar/minion_pki_ca.sls
  150. :language: yaml
  151. Salt minion with PKI certificate
  152. .. literalinclude:: tests/pillar/minion_pki_cert.sls
  153. :language: yaml
  154. Salt control (cloud/kvm/docker)
  155. -------------------------------
  156. Salt cloud with local OpenStack provider
  157. .. literalinclude:: tests/pillar/control_cloud_openstack.sls
  158. :language: yaml
  159. Salt cloud with Digital Ocean provider
  160. .. literalinclude:: tests/pillar/control_cloud_digitalocean.sls
  161. :language: yaml
  162. Salt virt with KVM cluster
  163. .. literalinclude:: tests/pillar/control_virt.sls
  164. :language: yaml
  165. Usage
  166. =====
  167. Working with salt-cloud
  168. .. code-block:: bash
  169. salt-cloud -m /path/to/map --assume-yes
  170. Debug LIBCLOUD for salt-cloud connection
  171. .. code-block:: bash
  172. export LIBCLOUD_DEBUG=/dev/stderr; salt-cloud --list-sizes provider_name --log-level all
  173. Read more
  174. =========
  175. * http://salt.readthedocs.org/en/latest/
  176. * https://github.com/DanielBryan/salt-state-graph
  177. * http://karlgrz.com/testing-salt-states-rapidly-with-docker/
  178. * https://mywushublog.com/2013/03/configuration-management-with-salt-stack/
  179. * http://russell.ballestrini.net/replace-the-nagios-scheduler-and-nrpe-with-salt-stack/
  180. * https://github.com/saltstack-formulas/salt-formula
  181. * http://docs.saltstack.com/en/latest/topics/tutorials/multimaster.html
  182. salt-cloud
  183. ----------
  184. * http://www.blog.sandro-mathys.ch/2013/07/setting-user-password-when-launching.html
  185. * http://cloudinit.readthedocs.org/en/latest/topics/examples.html
  186. * http://salt-cloud.readthedocs.org/en/latest/topics/install/index.html
  187. * http://docs.saltstack.com/topics/cloud/digitalocean.html
  188. * http://salt-cloud.readthedocs.org/en/latest/topics/rackspace.html
  189. * http://salt-cloud.readthedocs.org/en/latest/topics/map.html
  190. * http://docs.saltstack.com/en/latest/topics/tutorials/multimaster.html