diff --git a/provisioning/ansible/config/beetbox.config.yml b/provisioning/ansible/config/profiles/beetbox.config.yml similarity index 100% rename from provisioning/ansible/config/beetbox.config.yml rename to provisioning/ansible/config/profiles/beetbox.config.yml diff --git a/provisioning/ansible/playbook-config.yml b/provisioning/ansible/playbook-config.yml index a7cbf41..852657f 100644 --- a/provisioning/ansible/playbook-config.yml +++ b/provisioning/ansible/playbook-config.yml @@ -6,10 +6,11 @@ vars: beet_base: "{{ lookup('env','BEET_BASE') | default('/var/beetbox',true) }}" beet_user: "{{ lookup('env','BEET_USER') | default('vagrant',true) }}" + beet_profile: "{{ lookup('env','BEET_PROFILE') | default('beetbox',true) }}" ansible_home: "{{ lookup('env','ANSIBLE_HOME') | default('/beetbox/provisioning/ansible',true) }}" conf_dir: "{{ beet_base }}/.beetbox" conf_files: - - beetbox.config.yml + - "profiles/{{ beet_profile }}.config.yml" - project.config.yml - host.config.yml - config.yml diff --git a/provisioning/ansible/playbook-provision.yml b/provisioning/ansible/playbook-provision.yml index 7e5b83e..62c54eb 100644 --- a/provisioning/ansible/playbook-provision.yml +++ b/provisioning/ansible/playbook-provision.yml @@ -3,8 +3,11 @@ connection: local become: yes + vars: + beet_profile: "{{ lookup('env','BEET_PROFILE') | default('beetbox',true) }}" + vars_files: - - config/beetbox.config.yml + - "config/profiles/{{ beet_profile }}.config.yml" - config/project.config.yml - config/host.config.yml - config/config.yml diff --git a/provisioning/ansible/playbook-setup.yml b/provisioning/ansible/playbook-setup.yml index f2dbd14..67853de 100644 --- a/provisioning/ansible/playbook-setup.yml +++ b/provisioning/ansible/playbook-setup.yml @@ -3,16 +3,17 @@ connection: local become: yes + vars: + beet_profile: "{{ lookup('env','BEET_PROFILE') | default('beetbox',true) }}" + circleci: "{{ lookup('env','CIRCLECI') == 'true' }}" + vars_files: - - config/beetbox.config.yml + - "config/profiles/{{ beet_profile }}.config.yml" - config/project.config.yml - config/host.config.yml - config/config.yml - config/local.config.yml - vars: - circleci: "{{ lookup('env','CIRCLECI') == 'true' }}" - roles: - { role: beetbox-circleci, when: "{{ circleci }}"} - { role: beetbox-vagrant, when: "{{ lookup('env','VAGRANT_INIT') == 'true' }}"} diff --git a/provisioning/ansible/playbook-tests.yml b/provisioning/ansible/playbook-tests.yml index cbf2ec2..9d33024 100644 --- a/provisioning/ansible/playbook-tests.yml +++ b/provisioning/ansible/playbook-tests.yml @@ -3,8 +3,11 @@ connection: local become: yes + vars: + beet_profile: "{{ lookup('env','BEET_PROFILE') | default('beetbox',true) }}" + vars_files: - - config/beetbox.config.yml + - "config/profiles/{{ beet_profile }}.config.yml" - config/project.config.yml - config/host.config.yml - config/config.yml diff --git a/provisioning/ansible/playbook-update.yml b/provisioning/ansible/playbook-update.yml index b08254d..cd3e2bb 100644 --- a/provisioning/ansible/playbook-update.yml +++ b/provisioning/ansible/playbook-update.yml @@ -3,16 +3,17 @@ connection: local become: yes + vars: + beet_profile: "{{ lookup('env','BEET_PROFILE') | default('beetbox',true) }}" + beet_update: no + vars_files: - - config/beetbox.config.yml + - "config/profiles/{{ beet_profile }}.config.yml" - config/project.config.yml - config/host.config.yml - config/config.yml - config/local.config.yml - vars: - beet_update: no - tasks: - name: Create {{ beet_user }} user.