Browse Source

Reactor system, documentation fixes

Change-Id: Ic64656c6fc3d4f561226d884b8bfb535dd537e14
pr/fix/install_formulas_fix
Ales Komarek 7 years ago
parent
commit
5474068a16
6 changed files with 102 additions and 57 deletions
  1. +72
    -56
      README.rst
  2. +9
    -0
      salt/files/_reactor.conf
  3. +3
    -0
      salt/master/init.sls
  4. +17
    -0
      salt/master/reactor.sls
  5. +1
    -1
      tests/pillar/master_acl.sls
  6. +0
    -0
      tests/pillar/master_log_handler.sls

+ 72
- 56
README.rst View File



====
Salt
====
============
Salt Formula
============


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.
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.


Salt delivers a dynamic communication bus for infrastructures that can be used for orchestration, remote execution, configuration management and much more.
Salt delivers a dynamic communication bus for infrastructures that can be used
for orchestration, remote execution, configuration management and much more.


Sample Metadata
===============


Sample pillars
==============


Salt master Salt master
----------- -----------


Salt master with base production environment and pillar tree as metadata backend
Salt master with base formulas and pillar metadata backend


.. literalinclude:: tests/pillar/master_single_pillar.sls .. literalinclude:: tests/pillar/master_single_pillar.sls
:language: yaml :language: yaml


Salt master with reclass ENC as metadata backend
Salt master with reclass ENC metadata backend


.. literalinclude:: tests/pillar/master_single_reclass.sls .. literalinclude:: tests/pillar/master_single_reclass.sls
:language: yaml :language: yaml
minions: minions:
- name: 'node1.system.location.domain.com' - name: 'node1.system.location.domain.com'


Salt master with alternative installation source and version (optional) - pip
Salt master with pip based installation (optional)


.. code-block:: yaml .. code-block:: yaml


engine: pip engine: pip
version: 2016.3.0rc2 version: 2016.3.0rc2


Salt master with specified formula to install through apt-get
Install formula through system package management


.. code-block:: yaml .. code-block:: yaml


address: https://git.openstack.org/openstack/salt-formula-keystone address: https://git.openstack.org/openstack/salt-formula-keystone
revision: refs/changes/56/123456/1 revision: refs/changes/56/123456/1


Salt syndic: Master of masters

.. code-block:: yaml

salt:
master:
enabled: true
order_masters: True

Salt syndic: Lower master

.. code-block:: yaml

salt:
syndic:
enabled: true
master:
host: master-of-master-host
timeout: 5

Salt syndic: Lower master with multi-master of masters

.. code-block:: yaml

salt:
syndic:
enabled: true
masters:
- host: master-of-master-host1
- host: master-of-master-host2
timeout: 5


Salt master with custom handlers
Salt master with logging handlers


.. code-block:: yaml .. code-block:: yaml


host: 127.0.0.1 host: 127.0.0.1
port: 9999 port: 9999


Salt master peer for remote certificate sign.
Salt master peer setup for remote certificate signing


.. code-block:: yaml .. code-block:: yaml


master: master:
state_output: changes state_output: changes


Salt proxy
----------
Salt Reactor system configuration

.. code-block:: yaml

salt:
master:
reactor:
salt/minion/*/start:
- salt://reactor/minion-started.sls


Salt syndic
-----------

The master of masters

.. code-block:: yaml

salt:
master:
enabled: true
order_masters: True

Lower syndicated master

.. code-block:: yaml

salt:
syndic:
enabled: true
master:
host: master-of-master-host
timeout: 5

Syndicated master with multiple master of masters

.. code-block:: yaml

salt:
syndic:
enabled: true
masters:
- host: master-of-master-host1
- host: master-of-master-host2
timeout: 5


Salt-minion proxy
-----------------


Salt proxy pillar Salt proxy pillar


.. literalinclude:: tests/pillar/minion_graph.sls .. literalinclude:: tests/pillar/minion_graph.sls
:language: yaml :language: yaml


Salt minion behind http proxy
Salt minion behind HTTP proxy


.. code-block:: yaml .. code-block:: yaml


host: 127.0.0.1 host: 127.0.0.1
port: 3128 port: 3128


PKI CA
~~~~~~

Salt minion with PKI CA
Salt minion with PKI certificate authority (CA)


.. literalinclude:: tests/pillar/minion_pki_ca.sls .. literalinclude:: tests/pillar/minion_pki_ca.sls
:language: yaml :language: yaml


Salt minion with PKI certificate
Salt minion using PKI certificate


.. literalinclude:: tests/pillar/minion_pki_cert.sls .. literalinclude:: tests/pillar/minion_pki_cert.sls
:language: yaml :language: yaml
export LIBCLOUD_DEBUG=/dev/stderr; salt-cloud --list-sizes provider_name --log-level all export LIBCLOUD_DEBUG=/dev/stderr; salt-cloud --list-sizes provider_name --log-level all




Read more
=========
More Information
================


* http://salt.readthedocs.org/en/latest/ * http://salt.readthedocs.org/en/latest/
* https://github.com/DanielBryan/salt-state-graph * https://github.com/DanielBryan/salt-state-graph

+ 9
- 0
salt/files/_reactor.conf View File

{% from "salt/map.jinja" import master with context %}

reactor:
{%- for event, reactors in master.reactor.items() %}
- {{ event }}:
{%- for reactor in reactors %}
- {{ reactor }}
{%- endfor %}
{%- endfor %}

+ 3
- 0
salt/master/init.sls View File

include: include:
- salt.master.service - salt.master.service
{%- if pillar.salt.master.reactor is defined %}
- salt.master.reactor
{%- endif %}
- salt.master.env - salt.master.env
- salt.master.pillar - salt.master.pillar
- salt.master.minion - salt.master.minion

+ 17
- 0
salt/master/reactor.sls View File

{%- from "salt/map.jinja" import master with context %}
{%- if master.enabled %}

include:
- salt.master.service

/etc/salt/master.d/_reactor.conf:
file.managed:
- source: salt://salt/files/_reactor.conf
- user: root
- template: jinja
- require:
- {{ master.install_state }}
- watch_in:
- service: salt_master_service

{%- endif %}

+ 1
- 1
tests/pillar/master_acl.sls View File

salt: salt:
master: master:
command_timeout: 5 command_timeout: 5
worker_threads: 2
worker_threads: 3
enabled: true enabled: true
source: source:
engine: pkg engine: pkg

tests/pillar/master_custom_handler.sls → tests/pillar/master_log_handler.sls View File


Loading…
Cancel
Save