Skip to content

Instantly share code, notes, and snippets.

@yefim
yefim / Dockerrun.aws.json
Last active April 7, 2023 16:11
Build a Docker image, push it to AWS EC2 Container Registry, then deploy it to AWS Elastic Beanstalk
{
"AWSEBDockerrunVersion": "1",
"Image": {
"Name": "<AWS_ACCOUNT_ID>.dkr.ecr.us-east-1.amazonaws.com/<NAME>:<TAG>",
"Update": "true"
},
"Ports": [
{
"ContainerPort": "443"
}
@dwwoelfel
dwwoelfel / gist:b859cee4b5f41af37ffd
Created August 1, 2014 21:05
Rough notes for setting up elastic beanstalk on CircleCI

In your repo's root directory, check in a requirements.txt with

boto==2.30.0

Then, from the project's Project Settings > Environment Variables page, add the two env vars: AWS_ACCESS_KEY_ID and AWS_SECRET_KEY, with an IAM key that can deploy to eb.

Then create a bash script to set up eb:

@ndarville
ndarville / business-models.md
Last active October 23, 2024 17:18
Business models based on the compiled list at http://news.ycombinator.com/item?id=4924647. I find the link very hard to browse, so I made a simple version in Markdown instead.

Business Models

Advertising

Models Examples
Display ads Yahoo!
Search ads Google
@marktheunissen
marktheunissen / pedantically_commented_playbook.yml
Last active September 24, 2024 14:52 — forked from phred/pedantically_commented_playbook.yml
Insanely complete Ansible playbook, showing off all the options
This playbook has been removed as it is now very outdated.
@ederwander
ederwander / Speech.py
Created January 10, 2012 15:12
Real time VAD implementation using Google Speech Api
#Eng Eder de Souza 01/12/2011
#Speech Recognizer prototype ...
#Real time VAD implementation using Google Speech Api
from tempfile import mkstemp
from subprocess import call
from os import remove, listdir
from matplotlib.mlab import find
import pyaudio
import numpy as np
@gma
gma / gist:1476374
Created December 14, 2011 12:18
Noooooooo!
module Mongoid #:nodoc
module Components #:nodoc
extend ActiveSupport::Concern
# All modules that a +Document+ is composed of are defined in this
# module, to keep the document class from getting too cluttered.
included do
extend ActiveModel::Translation
extend Mongoid::Finders
end
@justinvoss
justinvoss / fabfile.py
Created June 20, 2011 16:05
Example Fabric and Cuisine Scrips
from deployment.cuisine import *
from fabric.api import *
from fabric.context_managers import *
from fabric.utils import puts
from fabric.colors import red, green
import simplejson
import os
@collegeman
collegeman / titanium-logging.js
Created February 14, 2011 03:19
I found this log() function very useful for exploring the Titanium API. The WebKit console is simply the best way to explore JavaScript objects. This implementation of a global log() function makes it easy to use the WebKit logger to inspect any object, i
(function(T, api) {
function log() {
if (window.console) {
window.console.log.apply(null, Array.prototype.slice.call(arguments));
} else {
api.prototype.log.apply(null, Array.prototype.slice.call(arguments));
}
}
T.UI.getMainWindow().showInspector(true);