Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How do I configure a jump host to access servers that I have no direct access to?



How do I configure a jump host to access servers that I have no direct access to?..

Answer / Israr Ahmad

To configure a jump host in Ansible, you can use the 'ansible_ssh_common_args' and 'ansible_ssh_extra_args' options. Here's an example playbook that demonstrates this:nn---
hosts: all            # Define inventory with servers behind a jump host
children:
bastionhost:n hosts:n - bastionhost.example.com    # Jump host configuration goes here servers:n vars:n ansible_ssh_common_args:    - "-o StrictHostKeyChecking=no"    # Common ssh args for all servers behind the jump host hosts:n - server1.example.com    # List of servers to be accessed through the jump host - server2.example.com    # Additional servers, if any
tasks:
- name: Test connection to servers    # Test SSH connectivity to each server through the jump host

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Ansible Interview Questions

Why is ‘{{ }}’ notation used? And how can one interpolate variables or dynamic variable names?

0 Answers  


Describe the working of ansible.

1 Answers  


Write an ansible playbook to automate the starting of ec2 instance.

1 Answers  


How is ansible different from puppet?

1 Answers  


How can you speed up management inside in ec2?

1 Answers  


Compare ansible with chef.

1 Answers  


When should I use {{ }}? Also, how to interpolate variables or dynamic variable names

1 Answers  


What is the use of ansible?

1 Answers  


How can one generate encrypted passwords for the user module?

1 Answers  


Explain different modules in ansible.

1 Answers  


What is ansible task?

1 Answers  


Compare ansible vs puppet?

1 Answers  


Categories