Changeset View
Changeset View
Standalone View
Standalone View
roles/paas-docker/containers/sentry.sls
| # ------------------------------------------------------------- | # ------------------------------------------------------------- | ||||
| # Salt — Provision Docker engine | # Salt — Provision Docker engine | ||||
| # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||
| # Project: Nasqueron | # Project: Nasqueron | ||||
| # Created: 2016-12-15 | # Created: 2016-12-15 | ||||
| # License: Trivial work, not eligible to copyright | # License: Trivial work, not eligible to copyright | ||||
| # ------------------------------------------------------------- | # ------------------------------------------------------------- | ||||
| {% set has_selinux = salt['grains.get']('selinux:enabled', False) %} | {% set has_selinux = salt['grains.get']('selinux:enabled', False) %} | ||||
| {% set containers = pillar['docker_containers'][grains['id']] %} | |||||
| # ------------------------------------------------------------- | # ------------------------------------------------------------- | ||||
| # Data directory | # Data directory | ||||
| # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||
| {% for realm, args in pillar['sentry_realms'].items() %} | {% for realm, args in pillar['sentry_realms'].items() %} | ||||
| /srv/sentry/{{ realm }}: | /srv/sentry/{{ realm }}: | ||||
| Show All 24 Lines | |||||
| {% endif %} | {% endif %} | ||||
| {% endfor %} | {% endfor %} | ||||
| # ------------------------------------------------------------- | # ------------------------------------------------------------- | ||||
| # Web application | # Web application | ||||
| # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||
| {% for instance, container in containers['sentry'].items() %} | {% for instance, container in pillar['docker_containers']['sentry'].items() %} | ||||
| {% set args = pillar['sentry_realms'][container['realm']] %} | {% set args = pillar['sentry_realms'][container['realm']] %} | ||||
| {{ instance }}: | {{ instance }}: | ||||
| docker_container.running: | docker_container.running: | ||||
| - detach: True | - detach: True | ||||
| - interactive: True | - interactive: True | ||||
| - image: library/sentry | - image: library/sentry | ||||
| Show All 15 Lines | |||||
| {% endfor %} | {% endfor %} | ||||
| # ------------------------------------------------------------- | # ------------------------------------------------------------- | ||||
| # Services containers | # Services containers | ||||
| # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||
| {% for service in ['worker', 'cron'] %} | {% for service in ['worker', 'cron'] %} | ||||
| {% for instance, container in containers['sentry_' + service].items() %} | {% for instance, container in pillar['docker_containers']['sentry_' + service].items() %} | ||||
| {% set args = pillar['sentry_realms'][container['realm']] %} | {% set args = pillar['sentry_realms'][container['realm']] %} | ||||
| {{ instance }}: | {{ instance }}: | ||||
| docker_container.running: | docker_container.running: | ||||
| - detach: True | - detach: True | ||||
| - interactive: True | - interactive: True | ||||
| - image: library/sentry | - image: library/sentry | ||||
| - binds: *binds | - binds: *binds | ||||
| - links: *links | - links: *links | ||||
| - environment: *env | - environment: *env | ||||
| - command: run {{ service }} | - command: run {{ service }} | ||||
| {% endfor %} | {% endfor %} | ||||
| {% endfor %} | {% endfor %} | ||||
Nasqueron DevCentral · If it had been much bigger the moon would have had a core of ice. · Powered by Phabricator