Skip to content
Snippets Groups Projects
Commit b45de002 authored by jurgenhaas's avatar jurgenhaas
Browse files

ansible-playbooks/general#85 Name import and include tasks

parent d19936d5
Branches
No related tags found
No related merge requests found
...@@ -54,26 +54,32 @@ ...@@ -54,26 +54,32 @@
failed_when: no failed_when: no
- block: - block:
- set_fact: - name: Set default facts
set_fact:
drupal_first_installation: no drupal_first_installation: no
- set_fact: - name: Set facts for first installation
set_fact:
drupal_first_installation: yes drupal_first_installation: yes
when: drupal_install_drupal and drupal_available is defined and drupal_available.stdout != [drupalRoot, '/index.php']|join('') when: drupal_install_drupal and drupal_available is defined and drupal_available.stdout != [drupalRoot, '/index.php']|join('')
tags: tags:
- always - always
- include_tasks: install/{{ installSource.mode|default("none") }}.yml - name: Include install mode
include_tasks: install/{{ installSource.mode|default("none") }}.yml
when: drupal_first_installation when: drupal_first_installation
- include_tasks: install/{{ drupal.version|default("d7") }}.yml - name: Include install version
include_tasks: install/{{ drupal.version|default("d7") }}.yml
when: drupal_first_installation when: drupal_first_installation
- include_tasks: deploy/{{ installSource.mode|default("none") }}.yml - name: Include deploy mode
include_tasks: deploy/{{ installSource.mode|default("none") }}.yml
when: drupal_install_drupal when: drupal_install_drupal
tags: tags:
- deploy - deploy
- include_tasks: deploy/{{ drupal.version|default("d7") }}.yml - name: Include deploy version
include_tasks: deploy/{{ drupal.version|default("d7") }}.yml
when: drupal_install_drupal when: drupal_install_drupal
tags: tags:
- deploy - deploy
...@@ -95,14 +101,16 @@ ...@@ -95,14 +101,16 @@
tags: tags:
- ApacheConfig - ApacheConfig
- include_tasks: scss.yml - name: Include scss
include_tasks: scss.yml
with_items: '{{ drupal.scss_dir|default([]) }}' with_items: '{{ drupal.scss_dir|default([]) }}'
loop_control: loop_control:
loop_var: scss_dir loop_var: scss_dir
tags: tags:
- deploy - deploy
- include_tasks: users/{{ installSource.mode|default("none") }}.yml - name: Include users mode
include_tasks: users/{{ installSource.mode|default("none") }}.yml
when: drupal_install_drupal and drupal.src is defined and drupal.src.name is defined when: drupal_install_drupal and drupal.src is defined and drupal.src.name is defined
tags: tags:
- SetPermissions - SetPermissions
...@@ -142,11 +150,13 @@ ...@@ -142,11 +150,13 @@
mode: 0775 mode: 0775
when: drupal.install_extra_dirs|default(true) when: drupal.install_extra_dirs|default(true)
- include_tasks: mountpoints.yml - name: Include mountpoints
include_tasks: mountpoints.yml
with_items: '{{ drupal.mountpoints|default([]) }}' with_items: '{{ drupal.mountpoints|default([]) }}'
when: drupal.install_extra_dirs|default(true) when: drupal.install_extra_dirs|default(true)
- include_tasks: files.yml - name: Include files
include_tasks: files.yml
with_nested: with_nested:
- '{{ drupal.domains }}' - '{{ drupal.domains }}'
- ['files', 'private'] - ['files', 'private']
...@@ -209,7 +219,8 @@ ...@@ -209,7 +219,8 @@
- deploy - deploy
when: drush_version_main|default('8') == '9' when: drush_version_main|default('8') == '9'
- include_tasks: deploy/finalize_{{ drupal.version|default("d7") }}.yml - name: Include deploy finalize version
include_tasks: deploy/finalize_{{ drupal.version|default("d7") }}.yml
when: drupal_install_drupal when: drupal_install_drupal
tags: tags:
- deploy - deploy
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment