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

bitegra/portal/drupal/projects/portal-default#8 Add support for drush aliases on stages

parent a143d4c9
No related branches found
No related tags found
No related merge requests found
......@@ -44,6 +44,15 @@
mode: 0664
when: drupal.create_drush_aliases|default(true)
- name: Configure Drush Aliases for Stages
template:
src: drush-9.stages.site.yml.jinja2
dest: '{{ webRoot }}/drush/sites/{{ drupal.id }}_stages.site.yml'
owner: root
group: root
mode: 0664
when: drupal.create_drush_aliases|default(true) and drupal.stage_ids is defined
- name: Configure Extra Drush Aliases
template:
src: drush-9-extra.site.yml.jinja2
......
{% for instance in drupal_settings %}
{% for stage_id in drupal.stage_ids %}
{% if stage_id == instance.id %}
{% if instance.jail is defined %}
{% set instanceWebRoot = [jailroot, instance.jail.name, 'var', 'www']|join('/') %}
{% else %}
{% set instanceWebRoot = ['/var/www', drupal.webRoot|default('')]|join('') %}
{% endif %}
{% for domain in instance.domains %}
{{ instance.src.git.branch }}:
root: {{ instanceWebRoot }}{{ instance.root|default("") }}/
uri: {{ domain.protocol|default("https") }}://{{ domain.domain }}
{% endfor %}
{% endif %}
{% endfor %}
{% endfor %}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment