Configuring generic system options on Arista devices
In this recipe, you will learn how to configure some basic system options, such as hostname and Domain Name System (DNS) servers. You will understand how to set up all these system-level parameters using various Ansible modules and learn the different ways to manage these parameters:
- The first update you need to make is to the
groups_vars/all.ymlfile. Here, the global defaults need to be specified so that you can access them programmatically, all while managing them from a single spot within the project:root@cookbook-lab:~/cookbook-lab/chapters/ch04# vi group_vars/all.yml --- global: mgmt_vrf: MGMT dns: - 8.8.8.8 - 8.8.4.4
In this case, you are adding a new dictionary key named dns, which is nested under the global root key. This is a simple list of IP addresses to define the DNS servers to be used...