-
Notifications
You must be signed in to change notification settings - Fork 135
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #153 from jbloomAus/ansible_dev
Ansible: dev only mode
- Loading branch information
Showing
6 changed files
with
86 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
instance_type: g6.xlarge |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
--- | ||
|
||
- name: "Launch dev instance" | ||
hosts: localhost | ||
vars_files: | ||
- "{{ lookup('env', 'PWD') ~ '/configs/shared.yml' }}" | ||
tasks: | ||
- name: Launch the EC2 Instance | ||
include_tasks: "{{ lookup('env', 'PWD') ~ '/tasks/launch_ec2_instance.yml' }}" | ||
vars: | ||
config_file: "{{ lookup('env', 'PWD') ~ '/configs/dev.yml' }}" | ||
service_name: "dev" | ||
job_name: "dev" | ||
|
||
- name: "Configure instance for job {{ job_name }}" | ||
hosts: tag_service__dev:&tag_job__{{ job_name }} | ||
gather_facts: true | ||
vars: | ||
ansible_user: ubuntu | ||
ansible_ssh_private_key_file: "{{ ssh_key_path }}" | ||
ansible_python_interpreter: auto_silent | ||
instance_storage_path: "{{ instance_storage_path }}" | ||
s3_local_cache_path: "{{ instance_storage_path }}/s3-local-cache" | ||
service_name: "dev" | ||
job_name: "dev" | ||
vars_files: | ||
- "{{ lookup('env', 'PWD') ~ '/configs/shared.yml' }}" | ||
tasks: | ||
- name: Configure the EC2 Instance | ||
include_tasks: "{{ lookup('env', 'PWD') ~ '/tasks/configure_ec2_instance.yml' }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
|
||
- name: Run Setup | ||
ansible.builtin.import_playbook: playbooks/setup.yml | ||
|
||
- name: Run Development Instance | ||
ansible.builtin.import_playbook: playbooks/dev.yml | ||
|
||
- name: Clear ansible.log | ||
hosts: localhost | ||
tasks: | ||
- name: Clear ansible.log | ||
ansible.builtin.copy: | ||
content: "" | ||
dest: "ansible.log" | ||
mode: '0644' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,4 +15,5 @@ filters: | |
instance-state-name: running | ||
tag:service: | ||
- cache_acts | ||
- train_sae | ||
- train_sae | ||
- dev |