Skip to content

Instantly share code, notes, and snippets.

View panbanda's full-sized avatar

Jonathan Reyes panbanda

View GitHub Profile
@panbanda
panbanda / tmux.md
Created May 17, 2016 10:46 — forked from andreyvit/tmux.md
tmux cheatsheet

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

@panbanda
panbanda / temporary-email-address-domains
Created April 30, 2016 06:22 — forked from adamloving/temporary-email-address-domains
A list of domains for disposable and temporary email addresses. Useful for filtering your email list to increase open rates (sending email to these domains likely will not be opened).
0-mail.com
0815.ru
0clickemail.com
0wnd.net
0wnd.org
10minutemail.com
20minutemail.com
2prong.com
30minutemail.com
3d-painting.com
@panbanda
panbanda / deploy.sh
Last active July 15, 2016 17:29
OpsWorks deploy script for multiple instances in a stack. Meant to work with Codeship.
# Install the aws cli client
pip install awscli
# List instances for a particular stack
OPSWORKS_STACK_ID="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
OPSWORKS_APP_ID="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
OPSWORKS_INSTANCE_LAYER_ID="XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
# Deploy the stack and app to instances found above
# This endpoint is only available in `us-east-1` even though
@panbanda
panbanda / cron.sh
Last active January 1, 2016 22:06
Unblock us cronjob IP updater
#!/bin/sh
# Variables (user specific)
userlogin="[email protected]"
userpassword="password"
# Environment
apiurl="https://api.unblock-us.com/login?$userlogin:$userpassword"
wgetcmd=$(which wget)
@panbanda
panbanda / installer.sh
Created December 20, 2015 08:06
Install Screaming Frog in the Amazon AWS Cloud
# Setting up Ubuntu
sudo apt-get update
sudo apt-get -y install xfce4 xfce4-goodies openjdk-7-jdk vnc4server
# Setup the login and configs
vncserver
vncserver -kill: 1
# Uncommenting settings required for normal vnc startup
sudo sed -i.bak s/"# exec"/"exec sh"/g ~/.vnc/xstartup
@panbanda
panbanda / vncserver
Created December 20, 2015 07:56
Starting up a VNC server in the cloud
#!/bin/bash
PATH="$PATH:/usr/bin/"
export USER="vnc"
DISPLAY="1"
DEPTH="16"
GEOMETRY="1024x768"
OPTIONS="-depth ${DEPTH} -geometry ${GEOMETRY} :${DISPLAY}"
. /lib/lsb/init-functions
case "$1" in
@panbanda
panbanda / google-analytics.amp.html
Created November 2, 2015 08:42 — forked from Mika-/google-analytics.amp.html
Use Google Analytics in AMP HTML
<amp-pixel src="https://ssl.google-analytics.com/collect?v=1&amp;tid=UA-12345678-1&amp;t=pageview&amp;cid=$RANDOM&amp;dt=$TITLE&amp;dl=$CANONICAL_URL&amp;z=$RANDOM"></amp-pixel>
/*
* Required parameters:
* v = API version number (currently 1)
* tid = Google Analytics property identifier (UA-12345678-1)
* t = hit type
* cid = client id (you should implement this via cookie etc.)
* z = random string to bypass caching (amphtml generates this to $RANDOM variable)
@panbanda
panbanda / notifier.rb
Created August 20, 2015 11:26
Slack Redmine Upcoming Deadlines
require 'rubygems'
require 'active_resource'
require "uri"
require "net/http"
slack = 'https://hooks.slack.com/services/XXX/XXX/XXX'
# Issue model on the client side
class Issue < ActiveResource::Base
self.site = 'https://redmine.stepfeed.com/'
@panbanda
panbanda / nginx.conf
Last active August 29, 2015 14:21 — forked from thoop/nginx.conf
# Change YOUR_TOKEN to your prerender token and uncomment that line if you want to cache urls and view crawl stats
# Change example.com (server_name) to your website url
# Change /path/to/your/root to the correct value
server {
listen 80;
server_name example.com;
root /path/to/your/root;
index index.html;

Setting up a SSL Cert from Comodo

I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.

These are the steps I went through to set up an SSL cert.

Purchase the cert