Skip to content

Commit

Permalink
Update post_software.yml - odf-dr-binder for EE (#7323)
Browse files Browse the repository at this point in the history
* Update post_software.yml - odf-dr-binder for EE

* Update post_software.yml

* Update post_software.yml

* Update post_software.yml
  • Loading branch information
bbethell-1 authored Nov 10, 2023
1 parent 5482d01 commit a03af16
Showing 1 changed file with 25 additions and 6 deletions.
31 changes: 25 additions & 6 deletions ansible/configs/odf-dr-binder/post_software.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,33 +12,52 @@
msg:
- Entering the odf-dr-binder post_software

#####################################
# Testing ssh keys
#####################################
- name: Store aws_hub_a private key
copy:
content: "{{ aws_hub_a_provision_data.ssh_provision_key }}\n"
dest: "{{ output_dir }}/aws_hub_a.pem"
mode: 0400

- name: Store aws_primary_a private key
copy:
content: "{{ aws_primary_a_provision_data.ssh_provision_key}}\n"
dest: "{{ output_dir }}/aws_primary_a.pem"
mode: 0400

- name: Store aws_secondry_a private key
copy:
content: "{{ aws_secondary_a_provision_data.ssh_provision_key }}\n"
dest: "{{ output_dir }}/aws_prod_cluster.pem"
mode: 0400


# In-Memory inventory
- name: add aws-hub to inventory
ansible.builtin.add_host:
name: "{{ aws_hub_a_provision_data.bastion_public_hostname }}"
groups: ohc_hub
ansible_connection: ssh
ansible_ssh_private_key_file: "~/.ssh/opentlc_admin_backdoor.pem"
ansible_ssh_private_key_file: "{{ output_dir }}/aws_hub_a.pem"
ansible_user: "ec2-user"
remote_user: "ec2-user"

- name: add aws-primary to inventory
ansible.builtin.add_host:
name: "{{ aws_primary_a_provision_data.bastion_public_hostname }}"
groups: ohc_aws_primary_a
ansible_connection: ssh
ansible_ssh_private_key_file: "~/.ssh/opentlc_admin_backdoor.pem"
ansible_ssh_private_key_file: "{{ output_dir }}/aws_primary_a.pem"
ansible_user: "ec2-user"
remote_user: "ec2-user"

- name: add aws-secondary to inventory
ansible.builtin.add_host:
name: "{{ aws_secondary_a_provision_data.bastion_public_hostname }}"
groups: ohc_aws_secondary_a
ansible_connection: ssh
ansible_ssh_private_key_file: "~/.ssh/opentlc_admin_backdoor.pem"
ansible_ssh_private_key_file: "{{ output_dir }}/aws_prod_cluster.pem"
ansible_user: "ec2-user"
remote_user: "ec2-user"

# Loggin into Cluster's bastion
- name: Logging into Hub
Expand Down

0 comments on commit a03af16

Please sign in to comment.