Ajout définitif des fichiers d'Ansible pour le DokuWiki.
This commit is contained in:
parent
66c8cdf08e
commit
d7115b7ffb
1
bts_annee_2/sisr2/ansible/dokuw/README.md
Normal file
1
bts_annee_2/sisr2/ansible/dokuw/README.md
Normal file
@ -0,0 +1 @@
|
|||||||
|
Dossier des playbooks DokuWiki.
|
51
bts_annee_2/sisr2/ansible/dokuw/main_doku.yml
Normal file
51
bts_annee_2/sisr2/ansible/dokuw/main_doku.yml
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
- name: 1. Récupération du tar.gz du DokuWiki
|
||||||
|
get_url:
|
||||||
|
url: http://depl/store/dokuwiki-stable.tgz
|
||||||
|
dest: /tmp
|
||||||
|
|
||||||
|
- name: 2. Extraction de l'archive
|
||||||
|
unarchive:
|
||||||
|
src: /tmp/dokuwiki-stable.tgz
|
||||||
|
dest: /var/www/html
|
||||||
|
remote_src: yes
|
||||||
|
|
||||||
|
- name: 3. Status des dossiers du Wiki
|
||||||
|
stat:
|
||||||
|
path: /var/www/html/dokuwiki-2024-02-06b
|
||||||
|
register: rept_stat
|
||||||
|
|
||||||
|
- name: 4. On renomme les dossiers
|
||||||
|
command: mv /var/www/html/dokuwiki-2024-02-06b /var/www/html/doku
|
||||||
|
when: rept_stat.stat.exists
|
||||||
|
|
||||||
|
- name: 5. Changement des droits sur la racine
|
||||||
|
file:
|
||||||
|
path: /var/www/html/doku
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
|
||||||
|
- name: 6. Changement des droits sur le dossier data
|
||||||
|
file:
|
||||||
|
path: /var/www/html/doku/data
|
||||||
|
owner: www-data
|
||||||
|
group: www-data
|
||||||
|
recurse: true
|
||||||
|
|
||||||
|
- name: 7. Changement des droits sur le dossier conf
|
||||||
|
file:
|
||||||
|
path: /var/www/html/doku/conf
|
||||||
|
owner: www-data
|
||||||
|
group: www-data
|
||||||
|
recurse: true
|
||||||
|
|
||||||
|
- name: 8. Changement des droits sur le dossier lib
|
||||||
|
file:
|
||||||
|
path: /var/www/html/doku/lib
|
||||||
|
owner: www-data
|
||||||
|
group: www-data
|
||||||
|
recurse: true
|
||||||
|
|
||||||
|
- name: 9. Redémarre Apache2
|
||||||
|
service:
|
||||||
|
name: apache2
|
||||||
|
state: restarted
|
Loading…
x
Reference in New Issue
Block a user