Coder Social home page Coder Social logo

ansible-config-audit's Introduction

published

Ansible Config Audit and Enforcement

Code to audit and enforce a gold standard config across a range of devices

Objective

This playbook, and the accompanying roles, are designed to illustrate how Ansible could be used to audit and enforce a set of baseline configs across multiple device types. The roles contain some sample configurations that might be included in an organization's baseline config, but they can be easily extended to add additional configs as well.

Requirements

To use this code you will need:

  • Python 3.6+

Optionally, this code can be run as is in a DevNet Cisco Modeling Labs sandbox

With the above sandbox, you instead will need:

  • Cisco VPN client - Setup instructions here
  • SSH client - Using Mac/Linux directly use the OS native SSH client. For connecting using an SSH client such as PuTTY

Install and Setup

  1. Reserve a Cisco Modeling Labs sandbox at DevNet Cisco Modeling Labs sandbox
  2. Once it is ready, click on the "Output" button, and use the VPN credentials to connect with AnyConnect or OpenConnect
  3. SSH to 10.10.20.50 as the developer user with password C1sco12345
  4. Execute the following to download pre-requisites: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/CiscoDevNet/ansible-config-audit/master/setup.sh)"
  5. Execute cd ansible-config-audit to change to the correct directory
  6. Execute ansible-playbook 1_audit.yml -C -v to see the state of the config audit
  7. Optionally execute ansible-playbook 1_audit.yml -v to deploy the gold config config
  8. Re-run ansible-playbook 1_audit.yml -C -v to see the new state of the config audit

Lab Topology:

Topology Diagram

Device list:

Device List

ansible-config-audit's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  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.