Skip to content
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

V1.0.0 beta #78

Merged
merged 38 commits into from
Jul 2, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
321f842
huge v1.0.0-beta overhaul
carlmontanari Jun 5, 2022
d1640d5
gitignore update
carlmontanari Jun 5, 2022
788215a
dont embed generic driver in netconf driver, add basic netconf example
carlmontanari Jun 5, 2022
4116843
hopefully fix gotestsum ci bits
carlmontanari Jun 5, 2022
cc1198b
hopefully fix gotestsum ci bits
carlmontanari Jun 5, 2022
ca9587b
dont output skipped dirs for gotestsum
carlmontanari Jun 5, 2022
4809972
.
carlmontanari Jun 5, 2022
4c159a6
.
carlmontanari Jun 5, 2022
d52504c
update makefile w/ clab dir rename
carlmontanari Jun 5, 2022
23bb320
add lock on transport close/read
carlmontanari Jun 5, 2022
2863dda
srl maybe
carlmontanari Jun 6, 2022
97c933b
sudo for clab start
carlmontanari Jun 6, 2022
5d8ad65
deprecate TimeoutTransport
carlmontanari Jun 14, 2022
ded8476
fix netconf channel close, update some tests/testdata
carlmontanari Jun 24, 2022
cd0cfd0
1s channel timeout for unit tests, maybe fix lock/unlock darwin issue
carlmontanari Jun 26, 2022
3ea689f
.
carlmontanari Jun 26, 2022
aa473bf
.
carlmontanari Jun 26, 2022
856d349
add startup config to xrv9k to limit ssh rate limiting
carlmontanari Jun 26, 2022
952173e
decrease channel read delay default
carlmontanari Jun 26, 2022
24c1c37
change q mutex to rw mutex to allow for checking q depth without full…
carlmontanari Jun 26, 2022
1cdcd95
delete messages from memory when fetched (netconf)
carlmontanari Jun 26, 2022
71edb81
remove redundant call to get messages (netconf)
carlmontanari Jun 26, 2022
ed6b1aa
test clean up and golden file regen
carlmontanari Jun 26, 2022
77ea720
include "ERROR" in cisco nxos failed when contains
carlmontanari Jun 27, 2022
3bad021
fix slow test (w/ race), add simple example to readme
carlmontanari Jun 28, 2022
b8a3648
bump golangci
carlmontanari Jun 28, 2022
3403e18
basic logging in netconf, standardize options setup
carlmontanari Jun 28, 2022
950a84d
notes about moving to 1.0.0
carlmontanari Jun 28, 2022
80c964e
add "ReadAll" method to fully drain channel queue
carlmontanari Jun 29, 2022
b2cf126
fix cisco iosxe escalate pattern
carlmontanari Jun 30, 2022
64cbf99
regen test to align with cisco iosxe escalate prompt update
carlmontanari Jun 30, 2022
90f7dbb
fix sendinteractive complete when patterns not returning when complete
carlmontanari Jun 30, 2022
34a4338
add SendInteractive to network driver so WithPrivilege works
carlmontanari Jun 30, 2022
034182a
simplify clean tests
carlmontanari Jul 1, 2022
87bd5f1
resolve platform from url/filepath
carlmontanari Jul 1, 2022
2a76e6f
add nokia/ipinfusion/palo platforms
carlmontanari Jul 1, 2022
db755f6
remove unnecessary nolint
carlmontanari Jul 1, 2022
e2df0e4
more test cleaning
carlmontanari Jul 2, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
37 changes: 37 additions & 0 deletions .clab/configs/ceos-startup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
! Command: show running-config
! device: ceos (cEOSLab, EOS-4.28.0F-26924507.4280F (engineering build))
!
no aaa root
!
username admin privilege 15 role network-admin secret sha512 $6$hB2JUt/ViRqix1FE$LeMDLUUvYUB9RcfqIWNYTZcvQX8lBHHeC5FjEkk/Uj3HJKw4fOTXMHNBU6/x3yS2hUrrM7m/xVTYzrQV5YLkD/
!
transceiver qsfp default-mode 4x10G
!
service routing protocols model multi-agent
!
hostname ceos
!
spanning-tree mode mstp
!
management api http-commands
no shutdown
!
management api gnmi
transport grpc default
!
management api netconf
transport ssh default
!
interface Ethernet1
!
interface Ethernet2
!
interface Management0
ip address 172.20.20.14/24
ipv6 address 2001:172:20:20::5/64
!
ip routing
!
ip route 0.0.0.0/0 172.20.20.1
!
end
80 changes: 80 additions & 0 deletions .clab/configs/xrv9k-startup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
hostname vr-xrv9k
username boxen
group root-lr
group cisco-support
secret 5 $1$Eqd9$r77Xc5HHjEiT.ushQEHMu1
!
username clab
group root-lr
group cisco-support
password 7 1511070D060A7A767B
!
call-home
service active
contact smart-licensing
profile CiscoTAC-1
active
destination transport-method http
!
!
interface MgmtEth0/RP0/CPU0/0
ipv4 address 10.0.0.15 255.255.255.0
!
interface GigabitEthernet0/0/0/0
shutdown
!
interface GigabitEthernet0/0/0/1
shutdown
!
interface GigabitEthernet0/0/0/2
shutdown
!
interface GigabitEthernet0/0/0/3
shutdown
!
interface GigabitEthernet0/0/0/4
shutdown
!
interface GigabitEthernet0/0/0/5
shutdown
!
interface GigabitEthernet0/0/0/6
shutdown
!
interface GigabitEthernet0/0/0/7
shutdown
!
interface GigabitEthernet0/0/0/8
shutdown
!
interface GigabitEthernet0/0/0/9
shutdown
!
interface GigabitEthernet0/0/0/10
shutdown
!
interface GigabitEthernet0/0/0/11
shutdown
!
interface GigabitEthernet0/0/0/12
shutdown
!
interface GigabitEthernet0/0/0/13
shutdown
!
interface GigabitEthernet0/0/0/14
shutdown
!
interface GigabitEthernet0/0/0/15
shutdown
!
grpc
port 57400
no-tls
!
netconf-yang agent
ssh
!
ssh server rate-limit 600
ssh server v2
ssh server netconf vrf default
12 changes: 12 additions & 0 deletions .clab/topo-ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
name: scrapligo

topology:
kinds:
srl:
image: ghcr.io/nokia/srlinux:21.11.3
nodes:
srl:
kind: srl
mgmt_ipv4: 172.20.20.16
mgmt_ipv6: 2001:172:20:20::16
50 changes: 50 additions & 0 deletions .clab/topo-full.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
name: scrapligo

topology:
kinds:
vr-csr:
image: boxen_cisco_csr1000v:16.12.03
vr-xrv9k:
image: boxen_cisco_xrv9k:6.5.3
vr-n9kv:
image: boxen_cisco_n9kv:9.2.4
ceos:
image: ceos:4.28.0F
vr-vqfx:
image: boxen_juniper_vsrx:17.3R2.10
srl:
image: ghcr.io/nokia/srlinux:21.11.3
nodes:
vr-csr:
kind: vr-csr
mgmt_ipv4: 172.20.20.11
mgmt_ipv6: 2001:172:20:20::11
vr-xrv9k:
kind: vr-xrv9k
mgmt_ipv4: 172.20.20.12
mgmt_ipv6: 2001:172:20:20::12
binds:
- configs/xrv9k-startup.cfg:/startup.cfg
env:
STARTUP_CONFIG: /startup.cfg
vr-n9kv:
kind: vr-n9kv
mgmt_ipv4: 172.20.20.13
mgmt_ipv6: 2001:172:20:20::13
ceos:
kind: ceos
mgmt_ipv4: 172.20.20.14
mgmt_ipv6: 2001:172:20:20::14
startup-config: configs/ceos-startup.cfg
vr-vqfx:
kind: vr-vqfx
mgmt_ipv4: 172.20.20.15
mgmt_ipv6: 2001:172:20:20::15
srl:
kind: srl
mgmt_ipv4: 172.20.20.16
mgmt_ipv6: 2001:172:20:20::16
links:
# forces "front panel port" for ceos, without this there is no ip routing
- endpoints: ["ceos:eth1", "ceos:eth2"]
5 changes: 2 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "sunday"
interval: "monthly"
timezone: "PST8PDT"
time: "03:00"
target-branch: "develop"
target-branch: "main"
59 changes: 50 additions & 9 deletions .github/workflows/commit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,61 @@ name: Commit
on: [push, pull_request, workflow_dispatch]

jobs:
build_posix:
unit-test:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 2
max-parallel: 6
matrix:
os: [ubuntu-latest, macos-latest]
go-version: [1.16.x]
go-version: ["1.16", "1.17", "1.18"]
steps:
- uses: actions/checkout@v2
- name: set up go ${{ matrix.version }}
- name: checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: set up go ${{ matrix.go-version }}
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- name: lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.45
- name: golangci-lint
run: golangci-lint run
version: v1.46
- name: install gotestsum
run: go install gotest.tools/gotestsum@latest
- name: tests
run: make test-race

functional-test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
go-version: ["1.18"]
runtime:
- "docker"
needs:
- unit-test
steps:
- name: checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: set up go ${{ matrix.go-version }}
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- name: install gotestsum
run: go install gotest.tools/gotestsum@latest
# pull the srl image before installing clab so that clab has no need to pull it when starting
# -- make sure this is the same image version that is in the clab ci topo!
- name: pull srlinux image
run: docker pull ghcr.io/nokia/srlinux:21.11.3
- name: install clab
run: bash -c "$(curl -sL https://get.containerlab.dev)" -- -v 0.26.2
- name: start clab ci topo
run: make deploy-clab-ci
- name: wait for srlinux node
run: sleep 60
- name: tests
run: go test -cover -v ./channel/... ./driver/... ./netconf/... ./logging/... ./transport/...
run: make test-ci
14 changes: 9 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# Output of the go coverage tool, specifically when used with LiteIDE
*.out

# goland
# jetbrains goodies
.idea

# macos stuff
Expand All @@ -20,13 +20,17 @@

# private dir for notes and such
private/
.private/

# log output
*.log

# mkdocs site
site/*

# vscode
.vscode
.devcontainer
.devcontainer

# coverage
cover.out

# clab build dir
.clab/clab-scrapligo
Loading