Skip to content

Instantly share code, notes, and snippets.

View jweede's full-sized avatar

Jon Wedaman jweede

View GitHub Profile
@jweede
jweede / ssllabs_check.py
Created November 27, 2019 15:44
Checks domains against ssllabs.
#!/usr/bin/env python3
"""
SSL Labs Testing API
https://github.com/ssllabs/ssllabs-scan/blob/master/ssllabs-api-docs-v3.md
"""
import logging
import re
import sys
import time
@jweede
jweede / pgbouncer.chart.py
Created February 26, 2019 16:18
Rough pgbouncer plugin for netdata
#!/usr/bin/env python
"""
Collects stats about pgbouncer client and postgres server connections
If psycopg2 is available it will use it instead of psql and will
query pgbouncer both for client and postgres server connections.
test out using:
/opt/netdata/usr/libexec/netdata/plugins.d/python.d.plugin 1 debug trace pgbouncer
@jweede
jweede / packer error.txt
Created August 4, 2016 15:01
Weird packer error about a missing file that wasn't there.
==> Some builds didn't complete successfully and had errors:
--> amazon-ebs: Error uploading local state tree to remote: lstat /home/jweede/_shoobx/cloud/salt-srv/salt/common.sls: no such file or directory
@jweede
jweede / bdt.py
Last active June 13, 2016 00:57
What does BDT stand for?
#!/usr/bin/env python2
import string
import random
class BDTGen(object):
def __init__(self):
self.words_dict = {
letter: []
@jweede
jweede / gist:8bd71917d926532f2dcb
Last active August 29, 2015 14:13
quick script for survey results
import sys
import csv
from collections import Counter
from itertools import chain
with open(sys.argv[1], 'rb') as csvfile:
dreader = csv.DictReader(csvfile)
key = 'What are you interested learning about more?'
c = Counter(chain.from_iterable(
@jweede
jweede / keybase.md
Created March 17, 2014 20:47
keybase.io

Keybase proof

I hereby claim:

  • I am jweede on github.
  • I am jweede (https://keybase.io/jweede) on keybase.
  • I have a public key whose fingerprint is 8967 C1BF FF9D C7B9 2D98 EA3B 2FDE D7F5 C38A 61B7

To claim this, I am signing this object:

@jweede
jweede / logo.sh
Created February 11, 2013 16:53
It's the future!
echo "
____ ______
/ __ )__ __/ / / /_ ____ _________
/ __ / / / / / / __ \/ __ \/ ___/ __ \\
/ /_/ / /_/ / / / / / / /_/ / / / / / /
/_____/\__,_/_/_/_/ /_/\____/_/ /_/ /_/
"
@jweede
jweede / log.out
Created May 17, 2012 14:11
`sudo port -d rev-upgrade` output
DEBUG: Ignoring loadcommand containing @executable_path in /Applications/MacPorts/MacVim.app/Contents/MacOS/MacVim
---> Scanning binaries for linking errors
Could not open /opt/local/lib/libpcre.0.dylib: Error opening or reading file (referenced from /opt/local/lib/libpcre++.0.0.0.dylib)
DEBUG: Marking /opt/local/lib/libpcre++.0.0.0.dylib as broken
DEBUG: skipping ppc in /Applications/MacPorts/iTerm2.app/Contents/Frameworks/Growl.framework/Versions/A/Growl since this system can't run it anyway
DEBUG: Ignoring loadcommand containing @executable_path in /Applications/MacPorts/iTerm2.app/Contents/MacOS/iTerm
DEBUG: Ignoring loadcommand containing @executable_path in /opt/local/libexec/llvm-3.0/bin/bugpoint
DEBUG: Ignoring loadcommand containing @executable_path in /opt/local/libexec/llvm-3.0/bin/llc
DEBUG: Ignoring loadcommand containing @executable_path in /opt/local/libexec/llvm-3.0/bin/lli
DEBUG: Ignoring loadcommand containing @executable_path in /opt/local/libexec/llvm-3.0/bin/llvm-ar
@jweede
jweede / gist:1041679
Created June 23, 2011 01:08
Excerpt from Knuth interview in "Coders At Work"

Seibel: It seems a lot of the people I've talked to had direct access to a machine when they were starting out. Yet Dijkstra has a paper I'm sure you're familiar with, where he basically says we shouldn't let computer-science students touch a machine for the first few years of their training: they should spend all their time manipulating symbols.

Knuth: But that's not the way he learned it either. He said a lot of really great things and inspirational things, but he's not always right. Neither am I, but my take on it is this: Take a scientist in any field. The scientist gets older and says, "Oh, yes, some of the things that I've been doing have a really great payoff and other things, I'm not using anymore. I'm not going to have my students waste time on the stuff that doesn't make giant steps. I'm not going to talk about low-level stuff at all. These theoretical concepts are really so powerful—that's the whole story. Forget about how I got to this point."

I think that's a fundamental error made by s