playbook ansible
This commit is contained in:
parent
32d6b7dbd1
commit
d18f102841
6
sio2/ANSIBLE/hosts
Normal file
6
sio2/ANSIBLE/hosts
Normal file
@ -0,0 +1,6 @@
|
||||
[adm]
|
||||
infra
|
||||
|
||||
[web]
|
||||
web1
|
||||
web2
|
20
sio2/ANSIBLE/web.yml
Normal file
20
sio2/ANSIBLE/web.yml
Normal file
@ -0,0 +1,20 @@
|
||||
---
|
||||
- name: web.yml
|
||||
hosts: web
|
||||
tasks:
|
||||
- name: 1. installer apache2
|
||||
apt :
|
||||
name: apache2
|
||||
state: present
|
||||
- name: 2 installer php-mbstring
|
||||
apt:
|
||||
name: php-mbstring
|
||||
state: present
|
||||
- name: 3 assurer Apache tourne
|
||||
service:
|
||||
name: apache2
|
||||
state: started
|
||||
- name: 4 copier le fichier index.html vers /var/www/html
|
||||
template:
|
||||
src: index.html
|
||||
dest: /var/www/html/
|
Loading…
x
Reference in New Issue
Block a user