Commit 9f69a045 authored by okhin's avatar okhin 🚴

Première base pour installer wordpress

parent bedbe764
---
- block:
become: yes
become_user: grange
- name: ajout d'un répertoire pour le core wordpress
file:
status: directory
src: "{{ wordpress_path }}"
mode: 0755
owner: "{{ wordpress_unix_user }}"
group: "{{ webserver_user }} "
- name: est-ce que wordpress est installé ?
command: "php {{ wordpress_wpcli_path }} core is-installed --path={{ wordpress_path }}"
register: wordpress
changed_when: "wordpress.rc >= 1"
- name: téléchargement de wordpress
command: "php {{ wordpress_wpcli_path }} core download --path={{ wordpress_path }}"
when: wordpress.changed
- name: installation de worpdress
command: "php {{ wordpress_wpcli_path }} core multisite-install --subdomains --path={{ wordpress_path }} --url={{ wordpress_url }} --title={{ wordpress_title }} --admin_user={{ wordpress_admin_user }} --admin-email={{ wordpress_admin_email }}"
when: wordpress.changed
- name: mise à jour de wordpress
command: "php {{ wordpress_wpcli_path }} core update --path={{ wordpress_path }}"
- name: mise à jour de la BDD de wordpress
command: "php {{ wordpress_wpcli_path }} core update-db --network --path={{ wordpress_path }}"
Markdown is supported
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