2018-08-23 15:51:55 +00:00
|
|
|
---
|
|
|
|
- name: get root folder of project
|
|
|
|
shell: pwd
|
|
|
|
register: proj_root
|
|
|
|
args:
|
|
|
|
chdir: "{{ playbook_dir }}/../../"
|
|
|
|
delegate_to: localhost
|
|
|
|
become: false
|
|
|
|
|
2018-08-23 18:10:17 +00:00
|
|
|
- name: remove underscores from folder name
|
|
|
|
set_fact:
|
|
|
|
proj_root_safe: "{{ proj_root.stdout|basename|replace('_','-') }}"
|
|
|
|
|
2018-08-23 15:51:55 +00:00
|
|
|
# These values are NOT honored by Vagrant, but are still necessary for DrupalVM
|
|
|
|
# See also provisioning/box/config
|
|
|
|
- name: set vagrant hostname according to the project folder
|
|
|
|
set_fact:
|
2018-08-24 02:56:43 +00:00
|
|
|
vagrant_hostname: "{{ proj_root_safe }}.test"
|
|
|
|
vagrant_machine_name: "{{ proj_root_safe }}-vm"
|