O'Reilly logo

JUNOS Automation Cookbook by Adam Chappell

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How to do it..

We're going to install the specific Python modules that enable the Ansible JUNOS_* modules to effectively communicate with JUNOS devices, routers, and switches. We'll also make some Ansible system changes in order to accommodate this.

  1. First of all, we're going to install the PyEZ JUNOS-eznc package on our Ansible control host because it contains some essential NETCONF-over-SSH functionality that Ansible will use:
  ubuntu@ubuntu-xenial:~$ pip install JUNOS-eznc  Collecting JUNOS-eznc  Collecting netaddr (from JUNOS-eznc)  Collecting PyYAML>=3.10 (from JUNOS-eznc)  Collecting pyserial (from JUNOS-eznc)  [...]  Successfully built ncclient  Installing collected packages: netaddr, PyYAML, pyserial,     setuptools, six, pycparser, cffi, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required