Commit 08b8dde4 authored by nono's avatar nono 💻
Browse files

Merge branch 'main' of git.laquadrature.net:lqdn-interne/piops-roles/don-lqdn

parents 5629f285 c046ebd9
---
# defaults file for don-lqdn
don_user_password: "change this password"
don_user_password: "change_this_password"
# SQL
don_sql_database: "don"
don_sql_user: "don"
don_sql_password: "change this password"
don_sql_password: "change_this_password"
# Payements
don_base_domain: "don.test.laquadrature.net"
......
- name: Installation des dépendances pour le site de don.
apt:
name: ['mariadb-server','default-mysql-client','gettext','git','bash','php','php-zip','php-mysql','pdftk','texlive-latex-base','python-mysql']
state: present
update_cache: true
- name: Téléchargement de l'installateur de composer
get_url:
url: https://raw.githubusercontent.com/composer/getcomposer.org/main/web/installer
......@@ -40,7 +34,7 @@
shell: composer -V
register: composer_output_install
failed_when: composer_output_install.rc != 0 or composer_output_install.rc > 0
become: true
become: no
become_user: don
- name: Création du dossier de don
......@@ -81,5 +75,14 @@
chdir: /home/don/don/
register: composer_output_install
failed_when: composer_output_install.rc != 0 or composer_output_install.rc > 0
become: true
become_user: don
# become: no
# become_user: don
- name: Vérification des permissions du dossier don
file:
state: directory
path: /home/don/don/
owner: don
group: don
mode: 0766
recurse: true
......@@ -18,19 +18,44 @@
shell: make reset-db
args:
chdir: /home/don/don
become: true
become_user: don
# become: true
# become_user: don
- name: Creation des dossiers pour le serveur de test
file:
state: directory
path: /home/don/don/log
owner: don
group: www-data
mode: 0770
- name: Lancement du serveur de test
shell: make server-start
args:
chdir: /home/don/don
- name: Attendons 5 secondes que le serveur soit bien lancé...
wait_for:
# On triche un peu
timeout: 5
- name: Exécution de tests
shell: make test
args:
chdir: /home/don/don
become: true
become_user: don
# become: true
# become_user: don
- name: Arrêt du serveur de test
shell: make server-stop
args:
chdir: /home/don/don
- name: Installation du site de don
shell: make install
args:
chdir: /home/don/don
become: true
become_user: don
# become: true
# become_user: don
---
# tasks file for don-lqdn
- include_tasks: setup.yml
- include: users.yml
- include: dependencies.yml
- include: database.yml
......
# Ce fichier se charge d'installer les éventulles dépendances dont Ansible à besoin.
- name: Installation des dépendances Ansible.
apt:
name: python3-mysqldb
state: latest
update_cache: true
- name: Installation des dépendances pour le site de don.
apt:
name: ['mariadb-server','default-mysql-client','gettext','git','bash','php','php-zip','php-dom','php-mbstring','make','php-curl','php-mysql','pdftk','texlive-latex-base','python-mysql']
state: present
update_cache: true
---
sysadmin_email: "test@example.com"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment