cisco / cisco.meraki / 2.9.0 / module / meraki_mx_l2_interface Configure MX layer 2 interfaces | "added in version" 2.1.0 of cisco.meraki" Authors: Kevin Breit (@kbreit) preview | supported by communitycisco.meraki.meraki_mx_l2_interface (2.9.0) — module
Install with ansible-galaxy collection install cisco.meraki:==2.9.0
collections: - name: cisco.meraki version: 2.9.0
Allows for management and visibility of Merkai MX layer 2 ports.
- name: Query layer 2 interface settings meraki_mx_l2_interface: auth_key: abc123 org_name: YourOrg net_name: YourNet state: query delegate_to: localhost
- name: Query a single layer 2 interface settings meraki_mx_l2_interface: auth_key: abc123 org_name: YourOrg net_name: YourNet state: query number: 2 delegate_to: localhost
- name: Update interface configuration meraki_mx_l2_interface: auth_key: abc123 org_name: YourOrg net_name: YourNet state: present number: 2 port_type: access vlan: 10 delegate_to: localhost
host: default: api.meraki.com description: - Hostname for Meraki dashboard. - Can be used to access regional Meraki environments, such as China. type: str vlan: description: - Native VLAN when the port is in Trunk mode. - Access VLAN when the port is in Access mode. type: int state: choices: - present - query default: present description: - Modify or query an port. type: str net_id: description: - ID number of a network. type: str number: aliases: - port - port_id description: - ID number of MX port. type: int org_id: description: - ID of organization associated to a network. type: str enabled: description: - Enabled state of port. type: bool timeout: default: 30 description: - Time to timeout for HTTP requests. type: int auth_key: description: - Authentication key provided by the dashboard. Required if environmental variable C(MERAKI_KEY) is not set. required: true type: str net_name: aliases: - name - network description: - Name of a network. type: str org_name: aliases: - organization description: - Name of organization. type: str port_type: choices: - access - trunk description: - Type of port. type: str use_https: default: true description: - If C(no), it will use HTTP. Otherwise it will use HTTPS. - Only useful for internal Meraki developers. type: bool use_proxy: default: false description: - If C(no), it will not use a proxy, even if one is defined in an environment variable on the target hosts. type: bool output_level: choices: - debug - normal default: normal description: - Set amount of debug output during module execution. type: str access_policy: choices: - open - 8021x-radius - mac-radius - hybris-radius description: - The name of the policy. Only applicable to access ports. type: str allowed_vlans: description: - Comma-delimited list of the VLAN ID's allowed on the port, or 'all' to permit all VLAN's on the port. type: str output_format: choices: - snakecase - camelcase default: snakecase description: - Instructs module whether response keys should be snake case (ex. C(net_id)) or camel case (ex. C(netId)). type: str validate_certs: default: true description: - Whether to validate HTTP certificates. type: bool drop_untagged_traffic: description: - Trunk port can Drop all Untagged traffic. When true, no VLAN is required. - Access ports cannot have dropUntaggedTraffic set to true. type: bool rate_limit_retry_time: default: 165 description: - Number of seconds to retry if rate limiter is triggered. type: int internal_error_retry_time: default: 60 description: - Number of seconds to retry if server returns an internal server error. type: int
data: contains: access_policy: description: - The name of the policy. Only applicable to access ports. returned: success sample: guestUsers type: str allowed_vlans: description: - Comma-delimited list of the VLAN ID's allowed on the port, or 'all' to permit all VLAN's on the port. returned: success sample: 1,5,10 type: str drop_untagged_traffic: description: - Trunk port can Drop all Untagged traffic. When true, no VLAN is required. - Access ports cannot have dropUntaggedTraffic set to true. returned: success sample: true type: bool enabled: description: - Enabled state of port. returned: success sample: true type: bool number: description: - ID number of MX port. returned: success sample: 4 type: int type: description: - Type of port. returned: success sample: access type: str vlan: description: - Native VLAN when the port is in Trunk mode. - Access VLAN when the port is in Access mode. returned: success sample: 1 type: int description: Information about the created or manipulated object. returned: success type: complex