Ver código fonte

current

master
pai
commit
8378c445d8
6 arquivos alterados com 44 adições e 4 exclusões
  1. +11
    -0
      handlers/main.yml
  2. +0
    -2
      meta/main.yml
  3. +0
    -2
      meta/main.yml~
  4. +9
    -0
      tasks/main.yml
  5. +14
    -0
      tasks/setup_Debian.yml
  6. +10
    -0
      templates/default-vhost.j2

+ 11
- 0
handlers/main.yml Ver arquivo

@@ -0,0 +1,11 @@
---

- name: restart apache
service:
name: apache2
state: restarted

- name: reload apache
service:
name: apache2
state: reloaded

+ 0
- 2
meta/main.yml Ver arquivo

@@ -1,2 +0,0 @@
dependencies:
- role: geerlingguy.apache

+ 0
- 2
meta/main.yml~ Ver arquivo

@@ -1,2 +0,0 @@
dependencies:

+ 9
- 0
tasks/main.yml Ver arquivo

@@ -0,0 +1,9 @@
---

- include: setup_Debian.yml

- name: default vhost
template:
src: default-vhost.j2
dest: /etc/apache2/sites-available/000-default.conf
notify: reload apache

+ 14
- 0
tasks/setup_Debian.yml Ver arquivo

@@ -0,0 +1,14 @@
---

- name: install apt packages
apt:
pkg: "{{item}}"
state: present
with_items:
- apache2
- libapache2-mod-php5

- name: remove default page
file:
path: /var/www/html/index.html
state: absent

+ 10
- 0
templates/default-vhost.j2 Ver arquivo

@@ -0,0 +1,10 @@
<VirtualHost *:80>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
DocumentRoot /var/www/html/
<Directory "/var/www/html/">
Options -Indexes
</Directory>
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

Carregando…
Cancelar
Salvar