Guillaume Coré
2020-01-16 48120620cb45ba4ed60bb2027d992daa608bac5f
Revert "ssh_config template update for bastion and set_env_authorized_key roles" (#1006)

This reverts commit 873d8f33340b0473b6e495392f4d0da588d769b9.
2 files modified
29 ■■■■■ changed files
ansible/roles/bastion/files/bastion_ssh_config.j2 16 ●●●●● patch | view | raw | blame | history
ansible/roles/set_env_authorized_key/files/host_ssh_config.j2 13 ●●●●● patch | view | raw | blame | history
ansible/roles/bastion/files/bastion_ssh_config.j2
@@ -1,4 +1,3 @@
{% if cloud_provider == 'ec2' %}
Host ec2* *.internal *.example.com
  User {{remote_user}}
{% if use_own_key|bool %}
@@ -10,18 +9,3 @@
  StrictHostKeyChecking no
  ConnectTimeout 60
  ConnectionAttempts 10
{% endif %}
{% if cloud_provider == 'osp' %}
{% set ip_octet = hostvars['bastion'].private_ip_address.split('.') %}
Host {{ ip_octet[0]+'.'+ip_octet[1] }}.*
  User {{remote_user}}
{% if use_own_key|bool %}
  IdentityFile ~/.ssh/{{env_authorized_key}}.pem
{% else %}
  IdentityFile ~/.ssh/{{key_name}}.pem
{% endif %}
  ForwardAgent yes
  StrictHostKeyChecking no
  ConnectTimeout 60
  ConnectionAttempts 10
{% endif %}
ansible/roles/set_env_authorized_key/files/host_ssh_config.j2
@@ -1,4 +1,3 @@
{% if cloud_provider == 'ec2' %}
Host ec2* *.internal *.example.com
   User {{remote_user}}
   IdentityFile ~/.ssh/{{env_authorized_key}}.pem
@@ -6,15 +5,3 @@
   StrictHostKeyChecking no
   ConnectTimeout 60
   ConnectionAttempts 10
{% endif %}
{% if cloud_provider == 'osp' %}
{% set ip_octet = hostvars['bastion'].private_ip_address.split('.') %}
Host {{ ip_octet[0]+'.'+ip_octet[1] }}.*
   User {{remote_user}}
   IdentityFile ~/.ssh/{{env_authorized_key}}.pem
   ForwardAgent yes
   StrictHostKeyChecking no
   ConnectTimeout 60
   ConnectionAttempts 10
{% endif %}