Skip to content

Instantly share code, notes, and snippets.

Greg Nilchee gnilchee

  • Evernote
  • Woodinville, WA
Block or report user

Report or block gnilchee

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
TSiege / The Technical Interview Cheat
Last active Jun 3, 2020
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.
View The Technical Interview Cheat


I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!


marcelom /
Created Dec 5, 2012
Tiny Python Syslog Server
#!/usr/bin/env python
## Tiny Syslog Server in Python.
## This is a tiny syslog server that is able to receive UDP based syslog
## entries on a specified port and save them to a file.
## That's it... it does nothing else...
## There are a few configuration parameters.
LOG_FILE = 'youlogfile.log'
weapp / nginx.conf
Created Aug 4, 2014
Return common errors as json in Nginx
View nginx.conf
error_page 500 /500.html;
location /500.html{
return 500 '{"error": {"status_code": 500,"status": "Internal Server Error"}}';
error_page 502 /502.html;
location /502.html{
return 502 '{"error": {"status_code": 502,"status": "Bad Gateway"}}';
z0mbix / tcpdump-es-capture
Created Dec 19, 2014
Capture Elasticsearch Queries
View tcpdump-es-capture
# tcpdump -A -nn -s 0 'tcp dst port 9200 and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)' -i lo
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on lo, link-type EN10MB (Ethernet), capture size 65535 bytes
14:32:33.525122 IP > Flags [P.], seq 313752908:313753888, ack 2465010394, win 257, options [nop,nop,TS val 2684167067 ecr 2684167066], length 980
..#...#.GET /index/_search HTTP/1.1
Accept: */*
Content-Length: 845
Content-Type: application/x-www-form-urlencoded
mapbutcher / EnableWinRm
Created Jul 17, 2013
Enable WinRM with basic auth
View EnableWinRm
set-executionpolicy -executionpolicy remotesigned
winrm quickconfig -q
winrm set winrm/config/winrs '@{MaxMemoryPerShellMB="512"}'
winrm set winrm/config '@{MaxTimeoutms="1800000"}'
winrm set winrm/config/service '@{AllowUnencrypted="true"}'
winrm set winrm/config/service/auth '@{Basic="true"}'
thisismitch /
Last active Mar 6, 2020
How To Use Terraform with DigitalOcean
resource "digitalocean_droplet" "haproxy-www" {
image = "ubuntu-14-04-x64"
name = "haproxy-www"
region = "nyc2"
size = "512mb"
private_networking = true
ssh_keys = [
connection {
dctrwatson / nginx.conf
Last active Mar 1, 2020
Caching PyPi packages locally with nginx
View nginx.conf
user www-data;
worker_processes 4;
error_log /var/log/nginx/error.log;
pid /var/run/;
events {
worker_connections 1024;
anti1869 /
Created Dec 21, 2015
How To Call Shell Commands From Python In Parallel With Asyncio
#!/usr/bin/env python
Test parallel scripts running with asyncio executors.
Requires at least Python 3.4 to run.
import asyncio
import os
ghoseb /
Created Nov 14, 2008
The evolution of a Python Programmer
#Newbie programmer
def factorial(x):
if x == 0:
return 1
return x * factorial(x - 1)
print factorial(6)
#First year programmer, studied Pascal
You can’t perform that action at this time.