Skip to content

Instantly share code, notes, and snippets.

View ghostrocket's full-sized avatar

Keith Fitzgerald ghostrocket

View GitHub Profile
@ghostrocket
ghostrocket / install-ffmpeg-amazon-linux.sh
Last active June 19, 2017 17:31 — forked from alfonsodev/install-ffmpeg-amazon-linux.sh
How to compile ffmpeg on Amazon Linux (EC2)
#!/bin/sh
# Based on gist.github.com/gboudreau/install-ffmpeg-amazon-linux.sh
# and https://trac.ffmpeg.org/wiki/CompilationGuide/Centos
if [ "`/usr/bin/whoami`" != "root" ]; then
echo "You need to execute this script as root."
exit 1
fi
cat > /etc/yum.repos.d/centos.repo<<EOF
@ghostrocket
ghostrocket / using-aws-kms.php
Created December 22, 2016 20:06 — forked from lysender/using-aws-kms.php
Using AWS KMS API via PHP SDK
<?php
use Aws\Kms\KmsClient;
// Somewhere in the controller or model
$this->load->config('aws');
// Not needed for EC2 instance role based authorization - for my local instance only
$key = $this->config->item('aws_s3_access_key');
$secret = $this->config->item('aws_s3_secret_key');
@ghostrocket
ghostrocket / gist:2208270
Created March 26, 2012 18:13 — forked from shripadk/gist:652819
Express authentication using Redis for session store and Couchdb for database (in coffeescript!)
###
Module dependencies
###
require.paths.unshift "#{__dirname}/lib/support/express-csrf/"
require.paths.unshift "#{__dirname}/lib/support/node_hash/lib/"
express = require 'express'
app = module.exports = express.createServer()
RedisStore = require 'connect-redis'

A Backbone.js demo app (Sinatra Backend)

Oct 16 2010

Updates

  • 04/10/2011 - Updated application.js and application.rb thanks to @rebo's comments

In this article, I will walk through some simple steps to get a [demo app][2] up and running with [Backbone.js][3] and [Sinatra][4] on [Heroku][5].