Skip to content

Instantly share code, notes, and snippets.

View jnyryan's full-sized avatar
💭
Working on Search... and guess what - search is hard

John Ryan jnyryan

💭
Working on Search... and guess what - search is hard
View GitHub Profile
@jnyryan
jnyryan / ubuntu_nginx_node.sh
Last active August 29, 2015 14:03
Ubuntu set up scripts
#!/bin/bash
####################
# Prerequisites
cd ~
pwd
# add apt-get-repository
apt-get install -y software-properties-common python-software-properties
#!/bin/bash
####################
# Prerequisites
sudo add-apt-repository -y ppa:chris-lea/node.js
# sudo add-apt-repository -y ppa:webupd8team/java # for ORACLE Java
sudo apt-get update
sudo apt-get install -y build-essential libncurses5-dev g++ make
@jnyryan
jnyryan / aws_ubuntu_setup.sh
Last active August 29, 2015 14:03
amason ubuntu image node web server setup
#!/bin/bash
####################
# Prerequisites
sudo add-apt-repository -y ppa:chris-lea/node.js
# sudo add-apt-repository -y ppa:webupd8team/java # for ORACLE Java
sudo apt-get update
sudo apt-get install -y build-essential libncurses5-dev g++ make
@jnyryan
jnyryan / aws_ami_setup.sh
Last active August 29, 2015 14:03
setup EC2 instance with node, nginx etc
#!/bin/sh
#################
# install prerequisites
sudo yum install -y gcc-c++ make
sudo yum install -y openssl-devel
sudo yum install -y git-core
sudo yum install -y curl
#################
@jnyryan
jnyryan / windows_profile.bat
Last active January 1, 2016 20:09
Set up aliases for windows command prompt
# Set up aliases for windows command prompt
echo creating cmd_aliases.txt
mkdir c:\Windows\CustomProfile
(
echo ls=dir
echo ps=tasklist $*
echo clear=cls
echo st=git status
@jnyryan
jnyryan / .bash_profile
Last active January 12, 2016 10:32
shell for ubuntu terminal, windows gitbash/cygwin and MacOSx Terminal.
# some aliases
alias ..="cd .."
alias ll='ls -alF'
alias la='ls -A'
alias l='ls -CF'
alias cls=clear
alias h='history'
# git
alias st='git status'
alias co='git checkout'
@jnyryan
jnyryan / ubuntu-setup-vpn.sh
Last active December 19, 2015 11:59
Set up the basics for OpenVPN on an Ubuntu 12.04 desktop.
#!/bin/sh
###################################################
# Install OpenVPN
###################################################
sudo apt-get install -y openvpn bridge-utils network-manager-openvpn
# This allows you to import settings into network-manager
# http://askubuntu.com/questions/187511/how-can-i-use-a-ovpn-file-with-network-manager
sudo apt-get install network-manager-openvpn-gnome
#!/bin/sh
###################################################
# Install basics on raspberry pi
# References
# http://www.cyberciti.biz/faq/deiban-ubuntu-linux-networkmanager-pptp-cisco-vpn-tab-disabled/
###################################################
sudo -i
apt-get update
@jnyryan
jnyryan / nessus-install.sh
Last active October 14, 2020 08:13
Install Nessus on Backtrack
#!/bin/sh
###################################################
# Install Nessus on Backtrack
###################################################
apt-get install nessus
/opt/nessus/sbin/nessus-adduser
/usr/local/bin/nessus-fetch --register 09ed-108c-c2a7-1947-64c8
/etc/init.d/nessusd start
@jnyryan
jnyryan / chrometime.py
Created February 26, 2013 20:35
DateTime converter for WebKit format to Epoch format. For use with SqlLite, e.g. echo "SELECT visits.visit_time, urls.url FROM urls, visits WHERE urls.id = visits.url;" | sqlite3 History | chrometime.py
#!/usr/bin/python
import sys
import time
#
# For every line in stdin
#
for line in sys.stdin:
try :
# Find the first field (the time)