-
Notifications
You must be signed in to change notification settings - Fork 792
Add aruba aoscx show system inventory #2339
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Ardeck
wants to merge
8
commits into
networktocode:master
Choose a base branch
from
Ardeck:feat/aruba_aoscx_show_system_inventory
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 3 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
cc6a198
wip: save work on current template
a4a7a51
feat(aruba_aoscx): add aruba_aoscx_show_system_inventory template
e2b0b61
feat(aruba_aoscx): fix index
e6efd25
Remove unneeded (default) Next action
mjbear 297bc5d
Modify leading whitespace and separator regex
mjbear fa68378
Support two word part types
mjbear 99feb76
Reduce test data duplication
mjbear ea8dd47
Remove commented location line
mjbear File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
ntc_templates/templates/aruba_aoscx_show_system_inventory.textfsm
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| Value TYPE (\S+) | ||
| Value LOCATION (\S+) | ||
| Value PRODUCT_NUMBER (\S+) | ||
| Value DESCRIPTION (.+?) | ||
| Value SERIAL (\S+) | ||
| Value HARDWARE_VERSION (\S+) | ||
|
|
||
| Start | ||
| ^\s*$$ | ||
| ^Type\s+Location -> Next | ||
| ^\s*Number -> Next | ||
| ^\s*[- \s]+\s*$$ -> Next | ||
| ^\s*${TYPE}\s+${LOCATION}\s+${PRODUCT_NUMBER}\s+${DESCRIPTION}\s+${SERIAL}\s+${HARDWARE_VERSION}\s*$$ -> Record | ||
| ^. -> Error "LINE NOT FOUND" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
tests/aruba_aoscx/show_system_inventory/aruba_aoscx_show_system_inventory.raw
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
|
|
||
| Type Location Product Description Serial Hardware | ||
| Number Number Version | ||
| -------------------- -------- ---------------- -------------------------------------------------- ---------------- ----------- | ||
| Chassis 1 JL635A Aruba 8325-48Y8C 48p 25G 8p 100G Swch ABCD1234EF 0 | ||
| Power Supply 1/1 JL632A Aruba 8325 650W 100-240VAC FB PSU ABCD1235EF -- | ||
| Power Supply 1/2 JL632A Aruba 8325 650W 100-240VAC FB PSU ABCD1236EF -- | ||
| Fan Tray-1/1 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/1 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/2 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/2 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/3 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/3 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/4 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/4 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/5 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/5 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/6 JL628A 8325 Fan Module -- -- | ||
| Fan Tray-1/6 JL628A 8325 Fan Module -- -- | ||
| Transceiver 1/1/1 J9151E 10G-LR / 10G SFP+ LR ABCD1237EF 1990-4694 | ||
| Transceiver 1/1/2 J9151E 10G-LR / 10G SFP+ LR ABCD1238EF 1990-4694 | ||
| Transceiver 1/1/8 J4859D 1G-LX / 1G SFP LX ABCD1239EF 1990-4802 | ||
| Transceiver 1/1/9 J4859D 1G-LX / 1G SFP LX ABCD1210EF 1990-4802 | ||
| Transceiver 1/1/10 J4858D 1G-SX / 1G SFP SX ABCD1211EF 1990-4750 | ||
| Transceiver 1/1/11 J4859D 1G-LX / 1G SFP LX ABCD1212EF 1990-4802 | ||
| Transceiver 1/1/12 J4858D 1G-SX / 1G SFP SX ABCD1213EF 1990-4750 | ||
| Transceiver 1/1/46 J4859D 1G-LX / 1G SFP LX ABCD1214EF 1990-4802 | ||
| Transceiver 1/1/47 J9151E 10G-LR / 10G SFP+ LR ABCD1215EF 1990-4694 | ||
| Transceiver 1/1/48 J9151E 10G-LR / 10G SFP+ LR ABCD1216EF 1990-4694 | ||
|
|
||
|
|
152 changes: 152 additions & 0 deletions
152
tests/aruba_aoscx/show_system_inventory/aruba_aoscx_show_system_inventory.yml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,152 @@ | ||
| --- | ||
| parsed_sample: | ||
| - description: "Aruba 8325-48Y8C 48p 25G 8p 100G Swch" | ||
| hardware_version: "0" | ||
| location: "1" | ||
| product_number: "JL635A" | ||
| serial: "ABCD1234EF" | ||
| type: "Chassis" | ||
| - description: "JL632A Aruba 8325 650W 100-240VAC FB PSU" | ||
| hardware_version: "--" | ||
| location: "Supply" | ||
| product_number: "1/1" | ||
| serial: "ABCD1235EF" | ||
| type: "Power" | ||
| - description: "JL632A Aruba 8325 650W 100-240VAC FB PSU" | ||
| hardware_version: "--" | ||
| location: "Supply" | ||
| product_number: "1/2" | ||
| serial: "ABCD1236EF" | ||
| type: "Power" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/1" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/1" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/2" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/2" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/3" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/3" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/4" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/4" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/5" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/5" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/6" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "8325 Fan Module" | ||
| hardware_version: "--" | ||
| location: "Tray-1/6" | ||
| product_number: "JL628A" | ||
| serial: "--" | ||
| type: "Fan" | ||
| - description: "10G-LR / 10G SFP+ LR" | ||
| hardware_version: "1990-4694" | ||
| location: "1/1/1" | ||
| product_number: "J9151E" | ||
| serial: "ABCD1237EF" | ||
| type: "Transceiver" | ||
| - description: "10G-LR / 10G SFP+ LR" | ||
| hardware_version: "1990-4694" | ||
| location: "1/1/2" | ||
| product_number: "J9151E" | ||
| serial: "ABCD1238EF" | ||
| type: "Transceiver" | ||
| - description: "1G-LX / 1G SFP LX" | ||
| hardware_version: "1990-4802" | ||
| location: "1/1/8" | ||
| product_number: "J4859D" | ||
| serial: "ABCD1239EF" | ||
| type: "Transceiver" | ||
| - description: "1G-LX / 1G SFP LX" | ||
| hardware_version: "1990-4802" | ||
| location: "1/1/9" | ||
| product_number: "J4859D" | ||
| serial: "ABCD1210EF" | ||
| type: "Transceiver" | ||
| - description: "1G-SX / 1G SFP SX" | ||
| hardware_version: "1990-4750" | ||
| location: "1/1/10" | ||
| product_number: "J4858D" | ||
| serial: "ABCD1211EF" | ||
| type: "Transceiver" | ||
| - description: "1G-LX / 1G SFP LX" | ||
| hardware_version: "1990-4802" | ||
| location: "1/1/11" | ||
| product_number: "J4859D" | ||
| serial: "ABCD1212EF" | ||
| type: "Transceiver" | ||
| - description: "1G-SX / 1G SFP SX" | ||
| hardware_version: "1990-4750" | ||
| location: "1/1/12" | ||
| product_number: "J4858D" | ||
| serial: "ABCD1213EF" | ||
| type: "Transceiver" | ||
| - description: "1G-LX / 1G SFP LX" | ||
| hardware_version: "1990-4802" | ||
| location: "1/1/46" | ||
| product_number: "J4859D" | ||
| serial: "ABCD1214EF" | ||
| type: "Transceiver" | ||
| - description: "10G-LR / 10G SFP+ LR" | ||
| hardware_version: "1990-4694" | ||
| location: "1/1/47" | ||
| product_number: "J9151E" | ||
| serial: "ABCD1215EF" | ||
| type: "Transceiver" | ||
| - description: "10G-LR / 10G SFP+ LR" | ||
| hardware_version: "1990-4694" | ||
| location: "1/1/48" | ||
| product_number: "J9151E" | ||
| serial: "ABCD1216EF" | ||
| type: "Transceiver" | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.