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

Drawing the graph

We'll create an HTML/JavaScript template, graph.html.template, based loosely on one of the many rich VivaGraph examples in order to interpret the JSON and invoke VivaGraph in order to make an interactive graph.

  1. First of all, make a directory for the project, download the VivaGraph library source from the repository on GitHub and extract the distribution library:
      $ mkdir graphdev      $ cd graphdev      $ git clone https://github.com/anvaka/VivaGraphJS.git      Cloning into 'VivaGraphJS'...      remote: Counting objects: 3135, done.      remote: Total 3135 (delta 0), reused 0 (delta 0), pack-reused                        3135      Receiving objects: 100% (3135/3135), 2.64 MiB | 1.44 MiB/s, done.      Resolving deltas: 100% (1673/1673), done.      $ cp VivaGraphJS/dist/vivagraph.js ...

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