Skip to content

Instantly share code, notes, and snippets.

automating the world

Apollo Clark apolloclark

automating the world
View GitHub Profile
View apache
<VirtualHost *>
WSGIApplicationGroup %{GLOBAL}
# Setup Python for the App1
WSGIDaemonProcess app1 user=www-data group=www-data threads=5
WSGIScriptAlias /app1 /var/www/app1/app1.wsgi
<Directory /var/www/app1>
Order deny,allow
Allow from all
View Python PIP Cheatsheet
# list package version available
pip install --no-deps --no-install <package_name> -v
View Gauntlt install for Kali Linux
# required distro packages
sudo apt-get -y install nmap curl libcurl3-dev rbenv libyaml-dev libxml2-dev libxslt-dev ruby1.9.1-dev
# Install Gauntlt
sudo gem install gauntlt
# install XMLLint, tidy
# @see
sudo apt-get install -y libxml2-utils tidy
View virtualbox cheatsheet
# add video mode
VBoxManage setextradata "VM_NAME" "CustomVideoMode1" "1280x720x32"
# set video mode
VBoxManage controlvm "VM_NAME" setvideomodehint 1280 720 32
View bash scripting

Bash Scripting Cheatsheet

This a collection of simple to advanced scripting techniques for Bash.

View python one
print all 255 ASCII characters in hex
for x in range(255): print hex(x),
View gist:7cd9703f899fb0de997b
diff --git a/ext/json/ext/fbuffer/fbuffer.h b/ext/json/ext/fbuffer/fbuffer.h
index af74187..9524fb1 100644
--- a/ext/json/ext/fbuffer/fbuffer.h
+++ b/ext/json/ext/fbuffer/fbuffer.h
@@ -172,7 +172,7 @@ static FBuffer *fbuffer_dup(FBuffer *fb)
static VALUE fbuffer_to_s(FBuffer *fb)
- VALUE result = rb_str_new(FBUFFER_PAIR(fb));
+ VALUE result = rb_str_new(FBUFFER_PTR(fb), FBUFFER_LEN(fb));
View Kali 2016.1, Railsgoat Install script
# @see
# update, install git
export DEBIAN_FRONTEND="noninteractive"
sudo apt-get update
sudo apt-get install -y git-core build-essential libssl-dev libreadline-dev \
libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev \
libcurl4-openssl-dev python-software-properties libffi-dev zlib1g-dev
View Data Science
  • What are you trying to solve?
  • Are you asking the right question?
  • Where is this data coming from?
  • Is this data recent? When? Where? Who?
  • Has this data been changed? How? Who? When?
  • Are there any strings?
    • is it formatted for Windows, Mac, or Linux (newlines)
    • should it have any non-ASCII?
    • how should non-ASCII be handled?
  • What are in each of the columns?
View gruyere

Docker SSH

# run the Gruyere container
docker run -d -p 8008:8008 karthequian/gruyere

# list running containers
You can’t perform that action at this time.