Skip to content

Instantly share code, notes, and snippets.

@gravyboat
Created June 11, 2014 17:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gravyboat/5b29084984af8fa7769e to your computer and use it in GitHub Desktop.
Save gravyboat/5b29084984af8fa7769e to your computer and use it in GitHub Desktop.
/srv/salt/nginx/init.sls
------------------------
install_nginx:
pkg:
- installed
- name: nginx
/srv/salt/nginx/config.sls
--------------------------
include:
- nginx
default_nginx_conf:
file:
- managed
- name: /etc/nginx/nginx.conf
- source: salt://nginx/files/nginx.conf
- require:
- sls: nginx
/srv/salt/python_app/nginx.sls
------------------------------
include:
- nginx.config
sites_enabled_python:
file:
- managed
- name: /etc/nginx/sites-enabled/python_app
- source: salt://python_app/files/python_app
- require:
- sls: nginx.config
/srv/salt/php_app/nginx.sls
------------------------------
include:
- nginx
php_nginx_config:
file:
- managed
- name: /etc/nginx/nginx.conf
- source: salt://php_app/files/nginx.conf
- require:
- sls: nginx
sites_enabled_php:
file:
- managed
- name: /etc/nginx/sites-enabled/php_app
- source: salt://python_app/files/php_app
- require:
- file: php_nginx_config
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment