Skip to content

Commit

Permalink
Feat(eos_cli_config_gen): Implement management-ssh client-alive (#3265)
Browse files Browse the repository at this point in the history
  • Loading branch information
gmuloc authored Oct 19, 2023
1 parent be6069f commit 3e4b44b
Show file tree
Hide file tree
Showing 8 changed files with 78 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,8 @@ management ssh
idle-timeout 15
connection limit 50
connection per-host 10
client-alive interval 666
client-alive count-max 42
no shutdown
log-level debug
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ management ssh
idle-timeout 15
connection limit 50
connection per-host 10
client-alive interval 666
client-alive count-max 42
no shutdown
log-level debug
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,6 @@ management_ssh:
- name: mgt
enable: true
log_level: debug
client_alive:
count_max: 42
interval: 666
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;- name</samp>](## "management_ssh.vrfs.[].name") | String | Required, Unique | | | VRF Name |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;enable</samp>](## "management_ssh.vrfs.[].enable") | Boolean | | | | Enable SSH in VRF |
| [<samp>&nbsp;&nbsp;log_level</samp>](## "management_ssh.log_level") | String | | | | SSH daemon log level |
| [<samp>&nbsp;&nbsp;client_alive</samp>](## "management_ssh.client_alive") | Dictionary | | | | |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;count_max</samp>](## "management_ssh.client_alive.count_max") | Integer | | | Min: 1<br>Max: 1000 | Number of keep-alive packets that can be sent without a response before the connection is assumed dead. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;interval</samp>](## "management_ssh.client_alive.interval") | Integer | | | Min: 1<br>Max: 1000 | Time period (in seconds) to send SSH keep-alive packets. |

=== "YAML"

Expand Down Expand Up @@ -61,4 +64,7 @@
- name: <str>
enable: <bool>
log_level: <str>
client_alive:
count_max: <int>
interval: <int>
```
Original file line number Diff line number Diff line change
Expand Up @@ -8735,6 +8735,30 @@
"type": "string",
"description": "SSH daemon log level",
"title": "Log Level"
},
"client_alive": {
"type": "object",
"properties": {
"count_max": {
"type": "integer",
"minimum": 1,
"maximum": 1000,
"description": "Number of keep-alive packets that can be sent without a response before the connection is assumed dead.",
"title": "Count Max"
},
"interval": {
"type": "integer",
"minimum": 1,
"maximum": 1000,
"description": "Time period (in seconds) to send SSH keep-alive packets.",
"title": "Interval"
}
},
"additionalProperties": false,
"patternProperties": {
"^_.+$": {}
},
"title": "Client Alive"
}
},
"additionalProperties": false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5210,6 +5210,24 @@ keys:
log_level:
type: str
description: SSH daemon log level
client_alive:
type: dict
keys:
count_max:
type: int
convert_types:
- str
min: 1
max: 1000
description: Number of keep-alive packets that can be sent without a response
before the connection is assumed dead.
interval:
type: int
convert_types:
- str
min: 1
max: 1000
description: Time period (in seconds) to send SSH keep-alive packets.
management_tech_support:
type: dict
keys:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,20 @@ keys:
log_level:
type: str
description: SSH daemon log level
client_alive:
type: dict
keys:
count_max:
type: int
convert_types:
- str
min: 1
max: 1000
description: Number of keep-alive packets that can be sent without a response before the connection is assumed dead.
interval:
type: int
convert_types:
- str
min: 1
max: 1000
description: Time period (in seconds) to send SSH keep-alive packets.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ management ssh
{% if management_ssh.connection.per_host is arista.avd.defined %}
connection per-host {{ management_ssh.connection.per_host }}
{% endif %}
{% if management_ssh.client_alive.interval is arista.avd.defined %}
client-alive interval {{ management_ssh.client_alive.interval }}
{% endif %}
{% if management_ssh.client_alive.count_max is arista.avd.defined %}
client-alive count-max {{ management_ssh.client_alive.count_max }}
{% endif %}
{% if management_ssh.cipher is arista.avd.defined %}
cipher {{ management_ssh.cipher | join(" ") }}
{% endif %}
Expand Down

0 comments on commit 3e4b44b

Please sign in to comment.