Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • ansible/roles/drupal
  • max/drupal
  • ericzillmann/drupal
3 results
Show changes
Commits on Source (1)
---
# file: roles/drupal/tasks/deploy/artefact.yml
- block:
- name: Ensure Repository Directory
file:
path: '{{ tempDeployRoot }}'
state: directory
owner: root
group: root
mode: u+rwX,g+rwX,o+rX
recurse: yes
follow: no
- name: Create .env file
template:
src: env.jinja2
dest: '{{ tempDeployRoot }}/.env'
owner: root
group: root
when: drupal.env is defined
tags:
- deploy
---
# file: roles/drupal/tasks/finalize/artefact.yml
- name: Move directories
command: mv /path/to/foo /path/to/bar
with_items:
- src: '{{ webRoot }}/files'
dest: '{{ tempDeployRoot }}'
- src: '{{ webRoot }}/settings'
dest: '{{ tempDeployRoot }}'
- src: '{{ webRoot }}/web/sites/default'
dest: '{{ tempDeployRoot }}/web/sites'
- src: '{{ webRoot }}'
dest: '{{ webRoot }}-old'
- src: '{{ tempDeployRoot }}'
dest: '{{ webRoot }}'
--- ---
# file: roles/drupal/tasks/deploy/finalize_d6.yml # file: roles/drupal/tasks/finalize/d6.yml
- name: Set facts - name: Set facts
set_fact: set_fact:
......
--- ---
# file: roles/drupal/tasks/deploy/finalize_d7.yml # file: roles/drupal/tasks/finalize/d7.yml
- name: Set facts - name: Set facts
set_fact: set_fact:
......
--- ---
# file: roles/drupal/tasks/deploy/finalize_d8.yml # file: roles/drupal/tasks/finalize/d8.yml
- block: - block:
......
...@@ -37,6 +37,10 @@ ...@@ -37,6 +37,10 @@
filesRoot: '{{ drupalRoot }}/sites' filesRoot: '{{ drupalRoot }}/sites'
settingsRoot: '{{ drupalRoot }}/sites' settingsRoot: '{{ drupalRoot }}/sites'
when: not drupal.files_outside_root|default(true) when: not drupal.files_outside_root|default(true)
- name: Set facts for artefact mode
set_fact:
tempDeployRoot: '{{ webRoot }}-{{ lookup("pipe","date +%Y-%m-%d-%H-%M-%S") }}'
when: installSource.mode|default("none") == 'artefact'
tags: tags:
- always - always
...@@ -58,6 +62,7 @@ ...@@ -58,6 +62,7 @@
follow: no follow: no
tags: tags:
- deploy - deploy
when: installSource.mode|default("none") == 'artefact'
- name: Check Installation Requirement - name: Check Installation Requirement
shell: ls {{ drupalRoot }}/index.php shell: ls {{ drupalRoot }}/index.php
...@@ -95,6 +100,14 @@ ...@@ -95,6 +100,14 @@
tags: tags:
- deploy - deploy
- name: Copy Artefacts
copy:
src: '{{ DRUPAL_ARTEFACT_SRC }}/'
dest: '{{ (installSource.mode|default("none") == "artefact")|ternary(tempDeployRoot,webRoot) }}/'
when: DRUPAL_ARTEFACT_SRC is defined
tags:
- deploy
- name: Ensure links - name: Ensure links
file: file:
src: '{{ webRoot }}{{ item.src }}' src: '{{ webRoot }}{{ item.src }}'
...@@ -254,17 +267,15 @@ ...@@ -254,17 +267,15 @@
- deploy - deploy
when: drush_version_main|default('8') == '9' when: drush_version_main|default('8') == '9'
- name: Include deploy finalize version - name: Include finalize mode
include_tasks: deploy/finalize_{{ drupal.version|default("d7") }}.yml include_tasks: finalize/{{ installSource.mode|default("none") }}.yml
when: drupal_install_drupal when: drupal_install_drupal and installSource.mode|default("none") == 'artefact'
tags: tags:
- deploy - deploy
- name: Copy Artefacts - name: Include finalize version
copy: include_tasks: finalize/{{ drupal.version|default("d7") }}.yml
src: '{{ DRUPAL_ARTEFACT_SRC }}/' when: drupal_install_drupal
dest: '{{ webRoot }}/'
when: DRUPAL_ARTEFACT_SRC is defined
tags: tags:
- deploy - deploy
......
---
# file: roles/drupal/tasks/install/artefact.yml
- name: Set facts
set_fact:
dummy: yes
---
# file: roles/drupal/tasks/users/artefact.yml
- name: Set facts
set_fact:
dummy: yes