Resource Type: cisco_yang

Defined in:
lib/puppet/type/cisco_yang.rb
Providers:
cisco

Overview

IOS-XR configuration management via YANG.

~~~puppet cisco_yang { ‘<title>’:

..attributes..

} ~~~ ‘<title>` is the title of the yang resource. Example: ~~~puppet

cisco_yang { 'blue vrf':
  ensure => present,
  target => '{\"Cisco-IOS-XR-infra-rsi-cfg:vrfs\": [null]}',
  source => '{\"Cisco-IOS-XR-infra-rsi-cfg:vrfs\": {
        \"vrf\":[
          {
              \"vrf-name\":\"blue\",
              \"vpn-id\":{
                \"vpn-oui\":875,
                \"vpn-index\":3
              },
              \"create\":[null]
          }
        ]
    }
  }',
}

~~~ ~~~puppet

cisco_yang { '{\"Cisco-IOS-XR-infra-rsi-cfg:vrfs\": [null]}':
  ensure => present,
  source => '{\"Cisco-IOS-XR-infra-rsi-cfg:vrfs\": {
        \"vrf\":[
          {
              \"vrf-name\":\"red\",
              \"vpn-id\":{
                \"vpn-oui\":875,
                \"vpn-index\":22
              },
              \"create\":[null]
          }
        ]
    }
  }',
}

~~~ ~~~puppet

cisco_yang {  '{\"Cisco-IOS-XR-infra-rsi-cfg:vrfs\": [null]}':
  ensure => absent,

~~~

Properties

  • ensure (defaults to: present)

    The basic property that the resource should be in.

    Supported values:
    • present
    • absent
  • source

Parameters

  • force
    Supported values:
    • true
    • false
  • mode
    Supported values:
    • replace
    • merge
  • provider

    The specific backend to use for this ‘cisco_yang` resource. You will seldom need to specify this — Puppet will usually discover the appropriate provider for your platform.

  • target (namevar)