gvasalt/states/gnuviechadmin/gvaweb.sls

20 lines
605 B
Text

{% set gvaappname = salt['pillar.get']('gnuviechadmin:appname') %}
{% set purpose = "for website configuration management" %}
{% from 'gnuviechadmin/gvaapp_macros.sls' import create_celery_worker with context %}
include:
- base
- python.pipenv
- python.virtualenv
{{ create_celery_worker(gvaappname, purpose) }}
/etc/sudoers.d/{{ gvaappname }}:
file.managed:
- user: root
- group: root
- source: salt://gnuviechadmin/{{ gvaappname }}/sudoers
- template: jinja
- context:
app_user: {{ salt['grains.get']('gnuviechadmin:user', gvaappname) }}
- require:
- pkg: sudo