This repository has been archived by the owner on Oct 1, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
34 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,8 +15,6 @@ | |
coresnippets: | ||
- features | ||
- vlans | ||
- vsans | ||
- fcalias | ||
- qos | ||
- ports | ||
- misc | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env python | ||
#/usr/bin/env python | ||
""" jinja2-nxos-config | ||
Accepts arguments from YAML config file | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{# handle different feature syntaxes - currently statically defining commands in list #} | ||
{% for feature in config|sort %} | ||
{{- feature }} | ||
{% endfor %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
hostname {{ config['hostname'] }} | ||
|
||
{# snmp-server user admin network-admin auth md5 -- priv -- localizedkey #} | ||
snmp-server host {{ config['snmp']['traphost'] }} traps version 2c public udp-port 2162 | ||
{# snmp-server community -- group network-operator #} | ||
{# snmp-server community -- use-acl acl_for_ro_comm #} | ||
|
||
{% for ntpserver in config['ntp'] -%} | ||
ntp server {{ ntpserver }} use-vrf management | ||
{% endfor %} | ||
{# TODO: Need to find a way to insert "prefer" keyword #} | ||
ntp source-interface mgmt0 | ||
|
||
vrf context management | ||
ip route 0.0.0.0/0 {{ config['mgmtgw']}} | ||
|
||
spanning-tree domain 101 | ||
spanning-tree vlan 1-4093 priority 4096 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
interface Ethernet {{ config['trunks'] }} | ||
switchport mode trunk | ||
{# need to have a loop here #} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
!VLAN Database | ||
{% for id, name in config|dictsort -%} | ||
vlan {{ id }} | ||
name {{ name }} | ||
{# fabricpath #} | ||
{% endfor %} |