cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
772
Views
10
Helpful
3
Replies

Commit DNA Center configuration template after update via API

BenEa
Level 1
Level 1

Hello,

I want to manage the lifecycle of my configuration templates through GitHub and have them sync with different DNA Center instances through the use of dynamic runners.

I have the same issue with both the terraform provider, and the Python dnacentersdk library.

I can update or create the template into the different DNA Center instances, but I cannot commit them.  There doesn´t seem to be a parameter to commit these templates via API.

Does someone know if this can be acheived?

Thanks!

 

DNA Center 2.3.3.4.72142

 

Python SDK:

https://dnacentersdk.readthedocs.io/en/latest/api/api.html#configuration-templates-2-3-3-0:~:text=configuration_archive-,configuration_templates,-device_onboarding_pnp

Terraform:

https://registry.terraform.io/providers/cisco-en-programmability/dnacenter/latest/docs/resources/configuration_template

 

1 Accepted Solution

Accepted Solutions

Andrea Testino
Cisco Employee
Cisco Employee

Hi there!

Have you tried setting the "version" parameter when using create_template or update_template when using the PythonSDK or when using the Terraform "dnacenter_configuration_template" resource? 

That should mark the template as committed and allow you to use it to deploy to devices.

The Template Management API doc shows the process (without using the PythonSDK or Terraform, though, the idea should be the same.)

I don't have a DNAC handy right now but let me know if that doesn't work and I can tinker with it this week.

- Andrea, CCIE #56739 R&S

View solution in original post

3 Replies 3

Andrea Testino
Cisco Employee
Cisco Employee

Hi there!

Have you tried setting the "version" parameter when using create_template or update_template when using the PythonSDK or when using the Terraform "dnacenter_configuration_template" resource? 

That should mark the template as committed and allow you to use it to deploy to devices.

The Template Management API doc shows the process (without using the PythonSDK or Terraform, though, the idea should be the same.)

I don't have a DNAC handy right now but let me know if that doesn't work and I can tinker with it this week.

- Andrea, CCIE #56739 R&S

BenEa
Level 1
Level 1

Thanks Andrea, with the python SDK .configuration_templates.version_template worked!  I couldn´t get it to work with the Terraform provider, I will stay with python on this one.

 

Awesome! Love to hear it.

- Andrea, CCIE #56739 R&S