cisco.mso.mso_schema_site_contract_service_graph_listener module – Manage the listener for Azure site contract service graph in schema sites
Note
This module is part of the cisco.mso collection (version 2.9.0).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install cisco.mso
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: cisco.mso.mso_schema_site_contract_service_graph_listener
.
Synopsis
Manage the listener for Azure site contract service graph in schema sites on Cisco ACI Multi-Site.
This module is only compatible with NDO versions 3.7 and 4.2+. NDO versions 4.0 and 4.1 are not supported.
Requirements
The below requirements are needed on the host that executes this module.
Multi Site Orchestrator v2.1 or newer
Parameters
Parameter |
Comments |
---|---|
The name of the contract. |
|
The name of the device. |
|
The frontend ip of the listener. Only supported for Network load balancers. |
|
IP Address or hostname of the ACI Multi Site Orchestrator host. If the value is not specified in the task, the value of environment variable |
|
The name of the listener. |
|
The port of the listener. |
|
The protocol of the listener. Choices:
|
|
The login domain name to use for authentication. The default value is Local. If the value is not specified in the task, the value of environment variable When using a HTTPAPI connection plugin the inventory variable |
|
Influence the output of this MSO module.
If the value is not specified in the task, the value of environment variable Choices:
|
|
The password to use for authentication. If the value is not specified in the task, the value of environment variables |
|
Port number to be used for the REST connection. The default value depends on parameter `use_ssl`. If the value is not specified in the task, the value of environment variable |
|
The rules of the listener. |
|
The action of the rule. |
|
The action type of the rule. Choices:
|
|
The content type of the rule. Choices:
|
|
The custom url of the rule. |
|
The floating ip of the rule. |
|
The health check of the rule. |
|
The host of the health check. The host attribute will be enabled when the use_host_from_rule is false. |
|
The interval of the health check. |
|
The path of the health check. |
|
The port of the health check. |
|
The protocol of the health check. Choices:
|
|
The success code of the health check. |
|
The timeout of the health check. |
|
The unhealthy threshold of the health check. |
|
The use host from rule of the health check. Choices:
|
|
The host of the rule. |
|
The name of the rule. |
|
The path of the rule. |
|
The port of the rule. |
|
The priority of the rule. |
|
The protocol of the rule. Choices:
|
|
The provider epg of the rule. |
|
The application profile name of the provider epg reference. |
|
The epg (Endpoint Group) name of the provider epg reference. |
|
The schema name of the provider epg reference. |
|
The template name of the provider epg reference. |
|
The redirect code of the rule. Choices:
|
|
The redirect host name of the rule. |
|
The redirect path of the rule. |
|
The redirect port of the rule. |
|
The redirect protocol of the rule. Choices:
|
|
The redirect query of the rule. |
|
The response body of the rule. |
|
The response code of the rule. |
|
The target ip type of the rule. Choices:
|
|
The url type of the rule. Choices:
|
|
The name of the schema. |
|
The security policy of the listener. Choices:
|
|
The index of the service node in the site contract service graph. The value starts from 0. |
|
The name of the site. |
|
The ssl certificates of the listener. |
|
The certificate store of the ssl certificate. Choices:
|
|
The name of the ssl certificate. |
|
Use Use Choices:
|
|
The name of the template. |
|
The name of the tenant. |
|
The socket level timeout in seconds. The default value is 30 seconds. If the value is not specified in the task, the value of environment variable |
|
If If the value is not specified in the task, the value of environment variable The default is Choices:
|
|
If If the value is not specified in the task, the value of environment variable When using a HTTPAPI connection plugin the inventory variable The default is Choices:
|
|
The username to use for authentication. If the value is not specified in the task, the value of environment variables |
|
If This should only set to If the value is not specified in the task, the value of environment variable The default is Choices:
|
Notes
Note
This module was written to support Multi Site Orchestrator v2.1 or newer. Some or all functionality may not work on earlier versions.
See Also
See also
- cisco.mso.mso_schema_template_contract_service_graph
Manage the service graph association with a contract in schema template.
Examples
- name: Add a listener for Network Load-Balancer
cisco.mso.mso_schema_site_contract_service_graph_listener:
host: mso_host
username: admin
password: SomeSecretPassword
contract: "Contract2"
schema: mso_schema
template: ansible_template1
site: mso_site
service_node_index: 0
listener: nlb_li_tcp
listener_port: 80
listener_protocol: tcp
tenant: mso_tenant
frontend_ip: "10.10.10.10"
device: ans_test_nlb
security_policy: default
rules:
- name: rule1
priority: 1
action_type: forward
port: 80
protocol: tcp
health_check:
port: 80
protocol: tcp
interval: 5
unhealthy_threshold: 2
success_code: 200-399
- name: Add a listener for Application Load-Balancer
cisco.mso.mso_schema_site_contract_service_graph_listener:
host: mso_host
username: admin
password: SomeSecretPassword
contract: "Contract2"
schema: mso_schema
template: ansible_template1
site: mso_site
service_node_index: 1
listener: aplb_li_https
tenant: mso_tenant
device: ans_test_aplb
listener_port: 443
listener_protocol: https
security_policy: default
ssl_certificates:
- name: ans_test_keyring
certificate_store: default
rules:
- name: rule1
priority: 1
action_type: forward
port: 80
protocol: http
provider_epg:
anp_name: AP1
epg_name: EPG1
health_check:
port: 80
protocol: http
path: "health_check_path"
interval: 30
timeout: 30
unhealthy_threshold: 3
use_host_from_rule: true
success_code: "200"
target_ip_type: unspecified
- name: Query all listeners
cisco.mso.mso_schema_site_contract_service_graph_listener:
host: mso_host
username: admin
password: SomeSecretPassword
contract: "Contract2"
schema: mso_schema
template: ansible_template1
site: mso_site
state: query
register: query_all_listeners
- name: Query all listeners with name ans_li_common
cisco.mso.mso_schema_site_contract_service_graph_listener:
host: mso_host
username: admin
password: SomeSecretPassword
contract: "Contract2"
schema: mso_schema
template: ansible_template1
site: mso_site
listener: ans_li_common
state: query
register: query_all_ans_li_common
- name: Query a listener with name - aplb_li_https
cisco.mso.mso_schema_site_contract_service_graph_listener:
host: mso_host
username: admin
password: SomeSecretPassword
contract: "Contract2"
schema: mso_schema
template: ansible_template1
site: mso_site
service_node_index: 1
listener: aplb_li_https
state: query
register: query_aplb_li_https
- name: Remove an existing listener - ans_li_common
cisco.mso.mso_schema_site_contract_service_graph_listener:
host: mso_host
username: admin
password: SomeSecretPassword
contract: "Contract2"
schema: mso_schema
template: ansible_template1
site: mso_site
service_node_index: 1
listener: aplb_li_https
state: absent