---

# Returns 'ansible_aws_params_file' which is where future playbooks can load params
- name: Load AWS config params
  include: ansible_aws_load_config.yml
  when: ansible_aws_load_config

- name: Login to AWS ECR
  include: ansible_aws_login_to_ecr.yml
  when: ansible_aws_login_to_ecr

# Bring up the instances we care about
# You always want this to run
- name: Launch any instances that we need
  include: ansible_aws_launch_instances.yml
  when: ansible_aws_launch

# Find all the currently running instances
- name: Get info about all the currently running instances
  include: ansible_aws_get_instances.yml
  when: ansible_aws_get_info
  vars:
    ansible_aws_state: running

# Push repos to ECR
- name: Push repos to ECR
  include: ansible_aws_push_to_ecr.yml
  when: ansible_aws_push_to_ecr
  vars:
    ansible_aws_state: running
---

# Returns 'ansible_aws_params_file' which is where future playbooks can load params
- name: Load AWS config params
  include: ansible_aws_load_config.yml
  when: ansible_aws_load_config

- name: Login to AWS ECR
  include: ansible_aws_login_to_ecr.yml
  when: ansible_aws_login_to_ecr

# Bring up the instances we care about
- name: Launch any instances that we need
  include: ansible_aws_launch_instances.yml
  when: ansible_aws_launch

# Bring up the instances we care about, when a list of subtypes is provided
- name: Launch any instances that we need
  include: ansible_aws_launch_instances.yml
  when: ansible_aws_launch
  with_items: "{{ ansible_aws_server_subtypes | default([]) }}"
  loop_control:
    loop_var: ansible_aws_server_subtype

# Find all the currently running instances
- name: Get info about all the currently running instances
  include: ansible_aws_get_instances.yml
  when: ansible_aws_get_info
  vars:
    ansible_aws_state: running

# Push repos to ECR
- name: Push repos to ECR
  include: ansible_aws_push_to_ecr.yml
  when: ansible_aws_push_to_ecr
  vars:
    ansible_aws_state: running
Add ability to launch multiple subtypes of a given server_type
Add ability to launch multiple subtypes of a given server_type
