Skip to content

Instantly share code, notes, and snippets.

View jabelk's full-sized avatar

Jason Belk jabelk

View GitHub Profile
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>AppleAntiAliasingThreshold</key>
<integer>1</integer>
<key>AppleScrollAnimationEnabled</key>
<integer>0</integer>
<key>AppleSmoothFixedFontsSizeThreshold</key>
<integer>1</integer>
@jabelk
jabelk / Brewfile
Last active October 15, 2022 02:12
tap "homebrew/bundle"
tap "homebrew/cask"
tap "homebrew/cask-fonts"
tap "homebrew/core"
tap "homebrew/services"
brew "openjdk"
brew "ant"
brew "awscli"
brew "python@3.9"
brew "coreutils"
1x Bag of Holding (m20)
1x Barren Moor (c21)
1x Bloodgift Demon (c14)
1x Cabal Stronghold (dom)
1x Caged Sun (mb1)
1x Castle Locthwain (eld)
1x Commander's Sphere (c21)
1x Court of Ambition (cmr)
1x Creeping Dread (soi)
1x Crypt Ghast (c14)
@jabelk
jabelk / .bash_profile
Created November 23, 2020 22:04
helpful aliases
export BASH_SILENCE_DEPRECATION_WARNING=1
# remove clutter from prompt
export PS1="\W$ "
export ANSIBLE_NOCOWS=1
alias mkgitignore='cat ~/.gitignore_global > .gitignore'
alias loginjumpsandbox='ssh developer@10.10.20.50'
alias loginjumpsandboxprod='ssh developer@10.10.20.49'
alias copysandboxkeys='sshpass -pC1sco12345 ssh-copy-id developer@10.10.20.50'
alias copysandboxkeysprod='sshpass -pC1sco12345 ssh-copy-id developer@10.10.20.49'
@jabelk
jabelk / iterm-preferences-belk.json
Created September 24, 2020 22:44
iterm preferences json
{
"Ansi 3 Color" : {
"Green Component" : 0.73333334922790527,
"Blue Component" : 0,
"Red Component" : 0.73333334922790527
},
"Tags" : [
],
"Ansi 12 Color" : {
CLI done to configure and then check output in YAML with ansible, then revert to send actual request:
developer@ncs(config)# services nso-snmp mytest_ro123 device dist-rtr01
developer@ncs(config-nso-snmp-mytest_ro123)# commit
Commit complete.
developer@ncs(config-nso-snmp-mytest_ro123)# no services nso-snmp mytest_ro123 device dist-rtr01
developer@ncs(config-nso-snmp-mytest_ro123)# commit
Commit complete.

Jinja2 to NSO Service Package

This package automatically creates NSO service models and packages from jinja2 templates of device config.

There are three main components:

  • A jinja2 to YANG translator.
  • A cookiecutter template for a model-driven jinja2 service package
  • A script to tie it all together
ncs-netsim create-network cisco-ios-cli-6.42 1 ios
ncs-netsim add-to-network cisco-nx-cli-5.13 1 nx
ncs-netsim add-to-network cisco-iosxr-cli-7.18 1 iosxr
ncs-netsim add-to-network cisco-asa-cli-6.7 1 asa
ncs-netsim start
ncs-netsim list
ncs_cli -C -u admin
config
@jabelk
jabelk / unpack.sh
Last active December 13, 2019 21:08
unpack neds from signed bin
downloadDirFiles=`ls ./ncs-5.*.signed.bin`
for eachned in $downloadDirFiles
do
sh $eachned
done
@jabelk
jabelk / Makefile
Created July 4, 2019 18:18
docker make
DOCKER_IMG = testexplorer
DOCKER_TAG = latest
CONTAINER_NAME = testexplorer-container
.PHONY: build
build:
docker build -t $(DOCKER_IMG):$(DOCKER_TAG) .
.PHONY: run