Class: Ansible::Ruby::Modules::Cv_server_provision

Inherits:
Base show all
Defined in:
lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb

Overview

This module allows a server team to provision server network ports for new servers without having to access Arista CVP or asking the network team to do it for them. Provide the information for connecting to CVP, switch rack, port the new server is connected to, optional vlan, and an action and the module will apply the configuration to the switch port via CVP. Actions are add (applies template config to port), remove (defaults the interface config) and show (returns the current port config).

Instance Method Summary collapse

Methods inherited from Base

#ansible_name, #to_h

Methods inherited from Ansible::Ruby::Models::Base

attr_option, attr_options, attribute, fix_inclusion, #initialize, remove_existing_validations, #to_h, validates

Constructor Details

This class inherits a constructor from Ansible::Ruby::Models::Base

Instance Method Details

#action:show, ...

Returns The action for the module to take. The actions are add, which applies the specified template config to port, remove, which defaults the specified interface configuration, and show, which will return the current port configuration with no changes.

Returns:

  • (:show, :add, :remove, nil)

    The action for the module to take. The actions are add, which applies the specified template config to port, remove, which defaults the specified interface configuration, and show, which will return the current port configuration with no changes.



51
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 51

attribute :action

#auto_run:yes, ...

Returns Flag that determines whether or not the module will execute the CVP task spawned as a result of changes to a switch configlet. When an add or remove action is taken which results in a change to a switch configlet, CVP will spawn a task that needs to be executed for the configuration to be applied to the switch. If this option is True then the module will determined the task number created by the configuration change, execute it and wait for the task to complete. If the option is False then the task will remain in the Pending state in CVP for a network administrator to review and execute.

Returns:

  • (:yes, :no, nil)

    Flag that determines whether or not the module will execute the CVP task spawned as a result of changes to a switch configlet. When an add or remove action is taken which results in a change to a switch configlet, CVP will spawn a task that needs to be executed for the configuration to be applied to the switch. If this option is True then the module will determined the task number created by the configuration change, execute it and wait for the task to complete. If the option is False then the task will remain in the Pending state in CVP for a network administrator to review and execute.



55
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 55

attribute :auto_run

#hostString

Returns The hostname or IP address of the CVP node being connected to.

Returns:

  • (String)

    The hostname or IP address of the CVP node being connected to.



12
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 12

attribute :host

#passwordString

Returns The password of the user that will be used to connect to CVP for API calls.

Returns:

  • (String)

    The password of the user that will be used to connect to CVP for API calls.



27
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 27

attribute :password

#portObject?

Returns The port number to use when making API calls to the CVP node. This will default to the default port for the specified protocol. Port 80 for http and port 443 for https.

Returns:

  • (Object, nil)

    The port number to use when making API calls to the CVP node. This will default to the default port for the specified protocol. Port 80 for http and port 443 for https.



16
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 16

attribute :port

#port_vlanInteger?

Returns The vlan that should be applied to the port for this server. This parameter is dependent on a proper template that supports single vlan provisioning with it. If a port vlan is specified by the template specified does not support this the module will exit out with no changes. If a template is specified that requires a port vlan but no port vlan is specified the module will exit out with no changes.

Returns:

  • (Integer, nil)

    The vlan that should be applied to the port for this server. This parameter is dependent on a proper template that supports single vlan provisioning with it. If a port vlan is specified by the template specified does not support this the module will exit out with no changes. If a template is specified that requires a port vlan but no port vlan is specified the module will exit out with no changes.



43
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 43

attribute :port_vlan

#protocol:https, ...

Returns The protocol to use when making API calls to CVP. CVP defaults to https and newer versions of CVP no longer support http.

Returns:

  • (:https, :http, nil)

    The protocol to use when making API calls to CVP. CVP defaults to https and newer versions of CVP no longer support http.



19
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 19

attribute :protocol

#server_nameString

Returns The hostname or identifier for the server that is having it’s switch port provisioned.

Returns:

  • (String)

    The hostname or identifier for the server that is having it’s switch port provisioned.



31
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 31

attribute :server_name

#switch_nameString

Returns The hostname of the switch is being configured for the server being provisioned.

Returns:

  • (String)

    The hostname of the switch is being configured for the server being provisioned.



35
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 35

attribute :switch_name

#switch_portInteger

Returns The physical port number on the switch that the new server is connected to.

Returns:

  • (Integer)

    The physical port number on the switch that the new server is connected to.



39
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 39

attribute :switch_port

#templateString

Returns A path to a Jinja formatted template file that contains the configuration block that will be applied to the specified switch port. This template will have variable fields replaced by the module before being applied to the switch configuration.

Returns:

  • (String)

    A path to a Jinja formatted template file that contains the configuration block that will be applied to the specified switch port. This template will have variable fields replaced by the module before being applied to the switch configuration.



47
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 47

attribute :template

#usernameString

Returns The user that will be used to connect to CVP for making API calls.

Returns:

  • (String)

    The user that will be used to connect to CVP for making API calls.



23
# File 'lib/ansible/ruby/modules/generated/network/cloudvision/cv_server_provision.rb', line 23

attribute :username