Skip to content

Instantly share code, notes, and snippets.

View nvd's full-sized avatar

Naveed Siddiqui nvd

  • Sydney, Australia
View GitHub Profile
@nvd
nvd / Gemfile
Last active February 14, 2019 02:16
swagger s3 cf
source 'https://rubygems.org'
gem 'aws-sdk', '~> 2.3'
@nvd
nvd / sqs-express.js
Created May 23, 2016 12:11
Nodejs app to push/pop with SQS
//-------------------------------------
// Nodejs app to push/pop with SQS
// $ npm install aws-sdk express
// $ node sqs-express.js
//-------------------------------------
var express = require('express'),
AWS = require('aws-sdk');
AWS.config.update({
@nvd
nvd / puppet_setup.sh
Created March 26, 2016 12:55
Puppet Single Node Setup
#!/bin/bash
#This script lists all commands for setting up an ubuntu instance with puppet master and agent
sudo su
export LOCAL_HOSTNAME=$(wget -qO- http://instance-data/latest/meta-data/local-hostname)
apt-get update
apt-get install -y puppet puppetmaster apache2
puppet agent --enable
mkdir /opt/hiera_data
@nvd
nvd / cleandb.sh
Created June 20, 2012 22:49
Cleans up, recreates and repopulates Postgres db in Rails app
#!/bin/sh
echo "Attempting to delete myapp_dev & myapp_test"
drop_the_database(){
local db=$1
local user=$2
psql $db $user << EOF
SELECT
pg_terminate_backend(procpid)
FROM
@nvd
nvd / cobaltish_coderay.scss
Created September 29, 2011 15:16
Stylesheet based on textmate's cobalt theme for coderay
$background_clr: #09223F;
$foreground_clr: #FFEFFF;
$border_clr: #888;
$line_no_background: #EFEFEF;
$line_no_foreground: #888;
$entity_clr: #FFDD00;
$keyword_clr: #FF9D00;
$constant_clr: #FF628C;
$string_clr: #3AD900;
$comment_clr: #0088FF;