Browse Source

refactor(redis): move redis_service to service.sls

tags/v1.0.0
Benjamin Neff 4 years ago
parent
commit
a8d08ff1eb
No account linked to committer's email address
2 changed files with 10 additions and 4 deletions
  1. +0
    -4
      diaspora/install.sls
  2. +10
    -0
      diaspora/service.sls

+ 0
- 4
diaspora/install.sls View File

redis_package: redis_package:
pkg.installed: pkg.installed:
- name: {{ diaspora.redis_package }} - name: {{ diaspora.redis_package }}

redis_service:
service.running:
- name: {{ diaspora.redis_service }}
{%- endif %} {%- endif %}


{% set home = diaspora.user.get('home', '/home/' + diaspora.user.username) -%} {% set home = diaspora.user.get('home', '/home/' + diaspora.user.username) -%}

+ 10
- 0
diaspora/service.sls View File

- context: - context:
diaspora: {{ diaspora|json }} diaspora: {{ diaspora|json }}


{%- if diaspora.install_redis %}
redis_service:
service.running:
- name: {{ diaspora.redis_service }}
- require:
- pkg: redis_package
- require_in:
- service: diaspora_service
{%- endif %}

diaspora_sidekiq_service: diaspora_sidekiq_service:
service.enabled: service.enabled:
- name: diaspora-sidekiq - name: diaspora-sidekiq

Loading…
Cancel
Save