cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4630
Views
2
Helpful
2
Replies

ACI Cobra SDK Examples

Allan Alfonso
Cisco Employee
Cisco Employee

Is there a repository of examples that we can leverage to help us write python scripts? I tried the ACI Toolkit but found it didn't have some features I needed so I went back to the cobra SDK. I also converted XML scripts from Cisco documentation using Arya but I am having trouble getting my scripts to work. The script executes without errors but does not appear to commit the configuration to the APIC so I must be missing something. I was hoping there might be more python examples available to use as a reference.

In short, I'm trying to write a script that configures the ACI fabric as one logical L2 switch with a simple EPG-to-VLAN mapping.

2 Replies 2

davbark2
Level 1
Level 1

I'm not aware of any code sample repositories other than what's available in Cisco · GitHub, but you might find something similar to what you're looking for in one of the demos on dCloud.cisco.com.  Create a log in and then schedule one or more sessions from the Application Centric Infrastructure pull-down.

tigephillips
Level 4
Level 4

In my github repository you will find a script that creates an EPG as a VLAN setup.  This does not setup an ACI environment from scratch (there are other scripts in the repository to do that if needed).

https://github.com/tigelane/cisco_aci-scripts