Skip to main content
added 20 characters in body
Source Link
sparkie
  • 2.3k
  • 1
  • 12
  • 11

just use a combined solution with properly setup ssh_config + resolv.conf:

1 . setup /etc/resolv.conf

search my_cool_domain.com

2 . setup your ssh_config for mapping between hosts and users

Host subdomain1
    User deploy1

Host subdomain2
    User deploy2

this way ssh subdomain1 will use the required user deploy1 and the host-ip will be foundqualified to it's full name by resolv.conf

just use a combined solution with properly setup ssh_config + resolv.conf:

1 . setup /etc/resolv.conf

search my_cool_domain.com

2 . setup your ssh_config for mapping between hosts and users

Host subdomain1
    User deploy1

Host subdomain2
    User deploy2

this way ssh subdomain1 will use the required user deploy1 and the host-ip will be found by resolv.conf

just use a combined solution with properly setup ssh_config + resolv.conf:

1 . setup /etc/resolv.conf

search my_cool_domain.com

2 . setup your ssh_config for mapping between hosts and users

Host subdomain1
    User deploy1

Host subdomain2
    User deploy2

this way ssh subdomain1 will use the required user deploy1 and the host will be qualified to it's full name by resolv.conf

Source Link
sparkie
  • 2.3k
  • 1
  • 12
  • 11

just use a combined solution with properly setup ssh_config + resolv.conf:

1 . setup /etc/resolv.conf

search my_cool_domain.com

2 . setup your ssh_config for mapping between hosts and users

Host subdomain1
    User deploy1

Host subdomain2
    User deploy2

this way ssh subdomain1 will use the required user deploy1 and the host-ip will be found by resolv.conf