Skip to content

Instantly share code, notes, and snippets.

View rnwilson's full-sized avatar

Nathan Wilson rnwilson

  • New Orleans, LA
View GitHub Profile
@rnwilson
rnwilson / install.sh
Created April 11, 2018 20:22 — forked from wdullaer/install.sh
Install Latest Docker and Docker-compose on Ubuntu
# Ask for the user password
# Script only works if sudo caches the password for a few minutes
sudo true
# Install kernel extra's to enable docker aufs support
# sudo apt-get -y install linux-image-extra-$(uname -r)
# Add Docker PPA and install latest version
# sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9
# sudo sh -c "echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list"
@rnwilson
rnwilson / nodejs-linux-installer.sh
Created April 25, 2018 03:01
nodejs-linux-installer
#!/bin/bash
echo "Node Linux Installer by www.github.com/taaem"
echo "Need Root for installing NodeJS"
sudo sh -c 'echo "Got Root!"'
echo "Get Latest Version Number..."
{
wget --output-document=node-updater.html https://nodejs.org/dist/latest/
@rnwilson
rnwilson / bash-cheatsheet.sh
Created April 28, 2018 21:56 — forked from LeCoupa/bash-cheatsheet.sh
Bash CheatSheet for UNIX Systems --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
#!/bin/bash
#####################################################
# Name: Bash CheatSheet for Mac OSX
#
# A little overlook of the Bash basics
#
# Usage:
#
# Author: J. Le Coupanec
# Date: 2014/11/04
@rnwilson
rnwilson / google-dorks
Created April 29, 2018 10:14 — forked from clarketm/google-dorks
Listing of a number of useful Google dorks.
" _ _ "
" _ /|| . . ||\ _ "
" ( } \||D ' ' ' C||/ { % "
" | /\__,=_[_] ' . . ' [_]_=,__/\ |"
" |_\_ |----| |----| _/_|"
" | |/ | | | | \| |"
" | /_ | | | | _\ |"
It is all fun and games until someone gets hacked!
@rnwilson
rnwilson / README.md
Created April 29, 2018 10:24 — forked from bobuss/README.md
Setup a Redis Cluster using docker-machine
@rnwilson
rnwilson / ssh-tunnel-snippet.txt
Created April 29, 2018 10:30
ssh tunnel snippit
ssh -D 8123 -f -C -q -N [email protected]
run locally then connect ssh to remote host for proxy
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
#cloud-config
# https://github.com/number5/cloud-init/blob/master/doc/examples/cloud-config.txt
package_update: true
runcmd:
# Docker
- curl -fsSL get.docker.com -o /tmp/get-docker.sh && sh /tmp/get-docker.sh
- wget https://dl.bintray.com/docker-compose/master/docker-compose-Linux-x86_64 -O /usr/local/bin/docker-compose && chmod +x /usr/local/bin/docker-compose
# Node.js
#common
alias cls='clear'
alias ipaddr='curl ifconfig.me'
## pass options to free ##
alias meminfo='free -m -l -t'
## get top process eating memory
alias psmem='ps auxf | sort -nr -k 4'
alias psmem10='ps auxf | sort -nr -k 4 | head -10'
export PATH=$PATH:/usr/local/go/bin