Giter Site home page Giter Site logo

dna-putty-sessions's Introduction

DNAC inventory to putty

This Python script connects to a Cisco DNA Center server via the API, queries the inventory and then adds the hostname/ip as SSH sessions in Putty for all devices on the users machine. Windows only

DevNet Code Exchange

This repository is featured on Cisco DevNet Code Exchange.

published

DNAC inventory

DNAC Inventory

Putty Sessions

Putty

Getting Started

This script is using the Cisco Devnet DNAC sandbox always on lab. You can connect to the GUI and view the documentation on the devnet sandbox site.

If using your own DNAC, you will need to enable the API package via the "Platform", section in DNA Center, documentation can be found on the Cisco developer site.

Running the code

  • Clone the repo:
    git clone https://gitlab.com/natilik/networking/dna-putty-sessions.git
  • Modify username, password and hostname in the dna_devices_to_putty.py file to connect to your preferred DNAC server. Note: Platform API package must be running (tested on 1.2.10)
  • At the command line:
C:\> cd dna-putty-sessions
C:\dna-putty-sessions> python -m venv venv
C:\dna-putty-sessions> venv\Scripts\activate
(venv) C:\dna-putty-sessions> pip install -r requirements.txt
(venv) C:\dna-putty-sessions> python dna_devices_to_putty.py

Prerequisites

  • Python 3.7.1
  • Putty
  • dnacmodule.py included in repo
  • requirements.txt included in repo:
Jinja2==2.10.1
requests==2.21.0
urllib3==1.24.2
xlrd==1.2.0
xlwt==1.3.0

To do

  • Expand to support other SSH applications e.g. SecureCRT

Authors

Licence

This project is licensed under the GNU GPLv3 Licence - see the Licence.md and Notice.md file for details

dna-putty-sessions's People

Contributors

darrenparkinson avatar dependabot[bot] avatar nonstdout avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.