Skip to content

Instantly share code, notes, and snippets.

@markberly
markberly / gist:6bf398697a7c4809ee72
Last active February 6, 2020 21:10
Monitor an interface on an Arista Networks EOS powered switch (via Python and eAPI) and uses Growl to provide its status
#!/usr/bin/python
#
# Written by: Mark Berly
import argparse
from jsonrpclib import Server
from gntp.notifier import mini
intf2Monitor = "Ethernet 48"
@markberly
markberly / yodaSpeaks.py
Created February 12, 2014 15:31
Let Yoda 'speak' a short python script that uses a API on Mashape API, found at: https://www.mashape.com/ismaelc/yoda-speak. You need to register and insert a Mashape-Authorization key in order to use the API. Have fun...
#!/usr/bin/python
import urllib2, urllib, argparse
# goto: https://www.mashape.com
# you need to create a Mashape account insert your key
# if you do not do this the script will fail
mashapeAuthorization = "MASHAPE_KEY"
def drawYoda () :