Skip to content

Commit

Permalink
Feat(eos_cli_config_gen): Support for setting default QSFP transceive…
Browse files Browse the repository at this point in the history
…r mode (aristanetworks#3271)

Co-authored-by: Carl Buchmann <carl.buchmann@arista.com>
Co-authored-by: Claus Holbech <holbech@arista.com>
  • Loading branch information
3 people authored Jan 22, 2024
1 parent 2cc7261 commit ca8e9f3
Show file tree
Hide file tree
Showing 10 changed files with 98 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# transceiver_qsfp_default_mode_4x10_false

## Table of Contents

- [Management](#management)
- [Management Interfaces](#management-interfaces)

## Management

### Management Interfaces

#### Management Interfaces Summary

##### IPv4

| Management Interface | Description | Type | VRF | IP Address | Gateway |
| -------------------- | ----------- | ---- | --- | ---------- | ------- |
| Management1 | oob_management | oob | MGMT | 10.73.255.122/24 | 10.73.255.2 |

##### IPv6

| Management Interface | Description | Type | VRF | IPv6 Address | IPv6 Gateway |
| -------------------- | ----------- | ---- | --- | ------------ | ------------ |
| Management1 | oob_management | oob | MGMT | - | - |

#### Management Interfaces Device Configuration

```eos
!
interface Management1
description oob_management
vrf MGMT
ip address 10.73.255.122/24
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
!RANCID-CONTENT-TYPE: arista
!
hostname transceiver_qsfp_default_mode_4x10_false
!
no enable password
no aaa root
!
interface Management1
description oob_management
vrf MGMT
ip address 10.73.255.122/24
!
end
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
transceiver_qsfp_default_mode_4x10: false
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,7 @@ terminattr-prem
terminattr-prem-no-ingestkey
terminattr-prem-disableaaa
traffic-policies
transceiver_qsfp_default_mode_4x10_false
tunnel-interfaces
unsupported-transceiver
vlan-interfaces
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,12 @@ roles/eos_cli_config_gen/docs/tables/port-channel-interfaces.md
roles/eos_cli_config_gen/docs/tables/switchport-default.md
--8<--

### Transceiver QSFP default mode 4x10

--8<--
transceiver-qsfp-default-mode-4x10.md
--8<--

### Tunnel interfaces

--8<--
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!--
~ Copyright (c) 2023-2024 Arista Networks, Inc.
~ Use of this source code is governed by the Apache License 2.0
~ that can be found in the LICENSE file.
-->
=== "Table"

| Variable | Type | Required | Default | Value Restrictions | Description |
| -------- | ---- | -------- | ------- | ------------------ | ----------- |
| [<samp>transceiver_qsfp_default_mode_4x10</samp>](## "transceiver_qsfp_default_mode_4x10") | Boolean | | `True` | | On all front panel ports which support this feature, the following global configuration command changes the QSFP mode from 40G to 4x10G (default). When set to false the command reverts the default QSFP mode back to 40G. |

=== "YAML"

```yaml
# On all front panel ports which support this feature, the following global configuration command changes the QSFP mode from 40G to 4x10G (default). When set to false the command reverts the default QSFP mode back to 40G.
transceiver_qsfp_default_mode_4x10: <bool; default=True>
```

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Copyright (c) 2023-2024 Arista Networks, Inc.
# Use of this source code is governed by the Apache License 2.0
# that can be found in the LICENSE file.
# yaml-language-server: $schema=../../../../plugins/plugin_utils/schema/avd_meta_schema.json
# Line above is used by RedHat's YAML Schema vscode extension
# Use Ctrl + Space to get suggestions for every field. Autocomplete will pop up after typing 2 letters.
type: dict
keys:
transceiver_qsfp_default_mode_4x10:
type: bool
default: true
description: |
On all front panel ports which support this feature, the following global configuration command changes the QSFP mode from 40G to 4x10G (default). When set to false the command reverts the default QSFP mode back to 40G.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#}
{# eos - transceiver qsfp default mode #}
{# cannot be disabled in current EOS releases #}
{% if not generate_default_config is arista.avd.defined(false) %}
{% if transceiver_qsfp_default_mode_4x10 | arista.avd.default(generate_default_config, true) %}
!
transceiver qsfp default-mode 4x10G
{% endif %}

0 comments on commit ca8e9f3

Please sign in to comment.