瀏覽代碼

Move sls files into correct directory structure, fixes #7

tags/v0.37.4
Joseph Hall 11 年之前
父節點
當前提交
ccb8fb6306
共有 6 個檔案被更改,包括 46 行新增56 行删除
  1. +0
    -0
      apache/fcgid.sls
  2. +46
    -9
      apache/init.sls
  3. +0
    -0
      apache/php5.sls
  4. +0
    -0
      apache/register_site.sls
  5. +0
    -0
      apache/rewrite.sls
  6. +0
    -47
      init.sls

fcgid.sls → apache/fcgid.sls 查看文件


+ 46
- 9
apache/init.sls 查看文件

@@ -1,10 +1,47 @@
apache2:
{% if grains['os_family'] == 'Debian' %}
pkg:
- installed
{% endif %}
service:
- running
- endable: True
include:
- apt
- apache.register_site

{% if grains['os']=="Ubuntu" %}

apache:
pkg.installed:
- name: apache2
- order: 175
service.running:
- name: apache2
- enable: True
- order: 455

a2dissite 000-default:
cmd.run:
- order: 225
- onlyif: ls /etc/apache2/sites-enabled/000-default
- watch_in:
- cmd: apache-reload
- require:
- pkg: apache2
- pkg: apache

apache-reload:
cmd.wait:
- name: service apache2 reload
- order: 420

apache-restart:
cmd.wait:
- name: service apache2 restart
- order: 425

/etc/apache2/sites-available/default:
file.absent:
- order: 230
- require:
- pkg: apache

/etc/apache2/sites-available/default-ssl:
file.absent:
- order: 230
- require:
- pkg: apache

{% endif %} #END: os = ubuntu

php5.sls → apache/php5.sls 查看文件


register_site.sls → apache/register_site.sls 查看文件


rewrite.sls → apache/rewrite.sls 查看文件


+ 0
- 47
init.sls 查看文件

@@ -1,47 +0,0 @@
include:
- apt
- apache.register_site

{% if grains['os']=="Ubuntu" %}

apache:
pkg.installed:
- name: apache2
- order: 175
service.running:
- name: apache2
- enable: True
- order: 455

a2dissite 000-default:
cmd.run:
- order: 225
- onlyif: ls /etc/apache2/sites-enabled/000-default
- watch_in:
- cmd: apache-reload
- require:
- pkg: apache

apache-reload:
cmd.wait:
- name: service apache2 reload
- order: 420

apache-restart:
cmd.wait:
- name: service apache2 restart
- order: 425

/etc/apache2/sites-available/default:
file.absent:
- order: 230
- require:
- pkg: apache

/etc/apache2/sites-available/default-ssl:
file.absent:
- order: 230
- require:
- pkg: apache

{% endif %} #END: os = ubuntu

Loading…
取消
儲存