GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - netascode/terraform-nxos-nac-nxos: Terraform Cisco NX-OS Network-as-Code Module

BranchesTags
Open more actions menu

Latest commit

 

History

432 Commits
432 Commits

Folders and files

NameName
Last commit message
Last commit date
.changelog
.changelog
 
 
.github
.github
 
 
defaults
defaults
 
 
examples/system
examples/system
 
 
nac
nac
 
 
scripts
scripts
 
 
.gitignore
.gitignore
 
 
.pre-commit-config.yaml
.pre-commit-config.yaml
 
 
.terraform-docs.yml
.terraform-docs.yml
 
 
CHANGELOG.md
CHANGELOG.md
 
 
LICENSE
LICENSE
 
 
Makefile
Makefile
 
 
README.md
README.md
 
 
main.tf
main.tf
 
 
nxos_access_list.tf
nxos_access_list.tf
 
 
nxos_analytics.tf
nxos_analytics.tf
 
 
nxos_bfd.tf
nxos_bfd.tf
 
 
nxos_bgp.tf
nxos_bgp.tf
 
 
nxos_bridge_domain.tf
nxos_bridge_domain.tf
 
 
nxos_default_qos.tf
nxos_default_qos.tf
 
 
nxos_dhcp.tf
nxos_dhcp.tf
 
 
nxos_eem.tf
nxos_eem.tf
 
 
nxos_eigrp.tf
nxos_eigrp.tf
 
 
nxos_epbr.tf
nxos_epbr.tf
 
 
nxos_esg.tf
nxos_esg.tf
 
 
nxos_evpn.tf
nxos_evpn.tf
 
 
nxos_feature.tf
nxos_feature.tf
 
 
nxos_hardware_telemetry.tf
nxos_hardware_telemetry.tf
 
 
nxos_hmm.tf
nxos_hmm.tf
 
 
nxos_hsrp.tf
nxos_hsrp.tf
 
 
nxos_icmpv4.tf
nxos_icmpv4.tf
 
 
nxos_icmpv6.tf
nxos_icmpv6.tf
 
 
nxos_igmp.tf
nxos_igmp.tf
 
 
nxos_igmp_snooping.tf
nxos_igmp_snooping.tf
 
 
nxos_ipv4.tf
nxos_ipv4.tf
 
 
nxos_ipv6.tf
nxos_ipv6.tf
 
 
nxos_isis.tf
nxos_isis.tf
 
 
nxos_keychain.tf
nxos_keychain.tf
 
 
nxos_logging.tf
nxos_logging.tf
 
 
nxos_loopback_interface.tf
nxos_loopback_interface.tf
 
 
nxos_macsec.tf
nxos_macsec.tf
 
 
nxos_management_interface.tf
nxos_management_interface.tf
 
 
nxos_msdp.tf
nxos_msdp.tf
 
 
nxos_netflow.tf
nxos_netflow.tf
 
 
nxos_network_qos.tf
nxos_network_qos.tf
 
 
nxos_ntp.tf
nxos_ntp.tf
 
 
nxos_nvo.tf
nxos_nvo.tf
 
 
nxos_ospf.tf
nxos_ospf.tf
 
 
nxos_ospfv3.tf
nxos_ospfv3.tf
 
 
nxos_physical_interface.tf
nxos_physical_interface.tf
 
 
nxos_pim.tf
nxos_pim.tf
 
 
nxos_platform.tf
nxos_platform.tf
 
 
nxos_poe.tf
nxos_poe.tf
 
 
nxos_port_channel_interface.tf
nxos_port_channel_interface.tf
 
 
nxos_ptp.tf
nxos_ptp.tf
 
 
nxos_queuing_qos.tf
nxos_queuing_qos.tf
 
 
nxos_route_policy.tf
nxos_route_policy.tf
 
 
nxos_segment_routing.tf
nxos_segment_routing.tf
 
 
nxos_sla.tf
nxos_sla.tf
 
 
nxos_snmp.tf
nxos_snmp.tf
 
 
nxos_span.tf
nxos_span.tf
 
 
nxos_spanning_tree.tf
nxos_spanning_tree.tf
 
 
nxos_subinterface.tf
nxos_subinterface.tf
 
 
nxos_svi_interface.tf
nxos_svi_interface.tf
 
 
nxos_system.tf
nxos_system.tf
 
 
nxos_telemetry.tf
nxos_telemetry.tf
 
 
nxos_track.tf
nxos_track.tf
 
 
nxos_user_management.tf
nxos_user_management.tf
 
 
nxos_vpc.tf
nxos_vpc.tf
 
 
nxos_vrf.tf
nxos_vrf.tf
 
 
nxos_vrrp.tf
nxos_vrrp.tf
 
 
nxos_vrrpv3.tf
nxos_vrrpv3.tf
 
 
nxos_vtp.tf
nxos_vtp.tf
 
 
outputs.tf
outputs.tf
 
 
variables.tf
variables.tf
 
 
versions.tf
versions.tf
 
 

Repository files navigation

Terraform Network-as-Code Cisco NX-OS Module

A Terraform module to configure Cisco NX-OS devices using Network as Code. The desired configuration of one or more switches is described in YAML and translated by the module into NX-OS provider resources, which are applied via NX-API.

Documentation

  • Introduction: concepts and architecture
  • First Steps: step-by-step guide from a single switch to multi-device deployments
  • Data Model Reference: all supported YAML attributes including types, ranges and examples
  • Supported Features
  • Changelog and Tested Versions

Prerequisites

  • NX-API enabled on each device (feature nxapi)
  • Device credentials provided via the NXOS_USERNAME and NXOS_PASSWORD environment variables

Usage

This module supports an inventory driven approach, where a complete NX-OS configuration or parts of it are either modeled in one or more YAML files (yaml_files, yaml_directories) or natively using Terraform variables (model).

Configuration is defined per device under nxos.devices. Settings shared across devices can be defined once using global configuration, device groups, templates, template instances and interface groups. The managed_devices and managed_device_groups variables can be used to limit which devices are managed by a Terraform run.

Examples

Configuring an NX-OS system configuration using YAML (see the system data model for all available attributes):

system.nac.yaml

nxos:
  devices:
    - name: Switch1
      url: https://1.2.3.4
      configuration:
        system:
          hostname: Switch1
          mtu: 9216

main.tf

module "nxos" {
  source  = "netascode/nac-nxos/nxos"
  version = ">= 0.1.0"

  yaml_files = ["system.nac.yaml"]
}

Requirements

Name Version
terraform >= 1.9.0
local >= 2.7.0, < 3.0.0
nxos ~> 0.23.0
utils >= 2.3.0, < 3.0.0

Inputs

Name Description Type Default Required
managed_device_groups List of device group names to be managed. By default all device groups will be managed. list(string) [] no
managed_devices List of device names to be managed. By default all devices will be managed. list(string) [] no
model As an alternative to YAML files, a native Terraform data structure can be provided as well. map(any) {} no
save_config Write changes to startup-config on all devices. bool false no
template_directories List of paths to directories containing template files. list(string) [] no
template_files List of paths to template files. list(string) [] no
write_model_file Write the rendered data model to a single YAML file, e.g. for validation, testing and troubleshooting. Value is a path relative to the root module. Set to an empty string to disable. string "model.yaml" no
yaml_directories List of paths to YAML directories. list(string) [] no
yaml_files List of paths to YAML files. list(string) [] no

Outputs

No outputs.

Resources

Name Type
local_sensitive_file.model resource
nxos_access_list.access_list resource
nxos_analytics.analytics resource
nxos_bfd.bfd resource
nxos_bgp.bgp resource
nxos_bridge_domain.bridge_domain resource
nxos_cli.cli_0 resource
nxos_cli.cli_1 resource
nxos_cli.cli_2 resource
nxos_cli.cli_3 resource
nxos_cli.cli_4 resource
nxos_cli.cli_5 resource
nxos_cli.cli_6 resource
nxos_cli.cli_7 resource
nxos_cli.cli_8 resource
nxos_cli.cli_9 resource
nxos_cli.cli_pre_0 resource
nxos_cli.cli_pre_1 resource
nxos_cli.cli_pre_2 resource
nxos_cli.cli_pre_3 resource
nxos_cli.cli_pre_4 resource
nxos_cli.cli_pre_5 resource
nxos_cli.cli_pre_6 resource
nxos_cli.cli_pre_7 resource
nxos_cli.cli_pre_8 resource
nxos_cli.cli_pre_9 resource
nxos_default_qos.default_qos resource
nxos_dhcp.dhcp resource
nxos_eem.eem resource
nxos_eigrp.eigrp resource
nxos_epbr.epbr resource
nxos_esg.esg resource
nxos_evpn.evpn resource
nxos_feature.feature resource
nxos_hardware_telemetry.hardware_telemetry resource
nxos_hmm.hmm resource
nxos_hsrp.hsrp resource
nxos_icmpv4.icmpv4 resource
nxos_icmpv6.icmpv6 resource
nxos_igmp.igmp resource
nxos_igmp_snooping.igmp_snooping resource
nxos_ipv4.ipv4 resource
nxos_ipv6.ipv6 resource
nxos_isis.isis resource
nxos_keychain.keychain resource
nxos_logging.logging resource
nxos_loopback_interface.loopback_interface resource
nxos_macsec.macsec resource
nxos_management_interface.management_interface resource
nxos_msdp.msdp resource
nxos_netflow.netflow resource
nxos_network_qos.network_qos resource
nxos_ntp.ntp resource
nxos_nvo.evpn_multihoming resource
nxos_nvo.nvo resource
nxos_ospf.ospf resource
nxos_ospfv3.ospfv3 resource
nxos_physical_interface.physical_interface resource
nxos_pim.pim resource
nxos_platform.platform resource
nxos_poe.poe resource
nxos_port_channel_interface.ethernet_segment resource
nxos_port_channel_interface.port_channel_interface resource
nxos_ptp.ptp resource
nxos_queuing_qos.queuing_qos resource
nxos_route_policy.route_policy resource
nxos_save_config.save_config resource
nxos_segment_routing.segment_routing resource
nxos_sla.sla resource
nxos_snmp.snmp resource
nxos_span.span resource
nxos_spanning_tree.spanning_tree resource
nxos_subinterface.subinterface resource
nxos_svi_interface.svi_interface resource
nxos_system.system resource
nxos_telemetry.telemetry resource
nxos_track.track resource
nxos_user_management.user_management resource
nxos_vpc.vpc resource
nxos_vrf.vrf resource
nxos_vrrp.vrrp resource
nxos_vrrpv3.vrrpv3 resource
nxos_vtp.vtp resource

Modules

No modules.

About

Terraform Cisco NX-OS Network-as-Code Module

registry.terraform.io/modules/netascode/nac-nxos/nxos

Topics

ciscoiacnacnetascodenetwork-as-codenexusnx-osnxosterraformterraform-module

Resources

Readme
Apache-2.0 license

Code of conduct

Code of conduct

Contributing

Contributing

Security policy

Security policy
Activity
Custom properties

Stars

10 stars

Watchers

3 watching

Forks

14 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.