Skip to content

Instantly share code, notes, and snippets.

View wyaeld's full-sized avatar
🐣
work in progress

Brad Murray wyaeld

🐣
work in progress
View GitHub Profile
@wyaeld
wyaeld / sidekiq.config
Created October 15, 2017 04:05 — forked from ssaunier/sidekiq.config
Running Sidekiq on AWS Elastic Beanstalk (Put that file in `.ebextensions` folder)
# Sidekiq interaction and startup script
commands:
create_post_dir:
command: "mkdir -p /opt/elasticbeanstalk/hooks/appdeploy/post"
ignoreErrors: true
files:
"/opt/elasticbeanstalk/hooks/appdeploy/post/50_restart_sidekiq.sh":
mode: "000755"
owner: root
group: root
@wyaeld
wyaeld / sidekiq.config
Created October 15, 2017 04:05 — forked from ssaunier/sidekiq.config
Running Sidekiq on AWS Elastic Beanstalk (Put that file in `.ebextensions` folder)
# Sidekiq interaction and startup script
commands:
create_post_dir:
command: "mkdir -p /opt/elasticbeanstalk/hooks/appdeploy/post"
ignoreErrors: true
files:
"/opt/elasticbeanstalk/hooks/appdeploy/post/50_restart_sidekiq.sh":
mode: "000755"
owner: root
group: root
@wyaeld
wyaeld / rails_logging.md
Created November 4, 2015 08:44 — forked from psahni/rails_logging.md
Rails Production with logging

Production Ready Process Monitoring

  1. Install docker-manger.conf and docker-instance.conf in /etc/init

  2. Create a containers file in /etc/docker/ with the following format

     name: image cmd
    

    The name must be unique.

  3. sudo service docker-manager start

@wyaeld
wyaeld / 0_reuse_code.js
Created November 28, 2013 20:57
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
#!/usr/bin/env python
#http://ozkatz.github.io/ssh-into-your-ec2-instances-with-ease.html
import os
import sys
import argparse
try:
from boto.ec2.connection import EC2Connection
except ImportError:
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<script src="http://d3js.org/d3.v3.min.js"></script>
<script src="http://code.jquery.com/jquery-1.8.3.min.js"></script>
<script src="https://raw.github.com/timrwood/moment/1.6.0/min/moment.min.js"></script>
<style type="text/css">
#chart-mini {
@wyaeld
wyaeld / index.html
Created January 23, 2013 00:38 — forked from mbostock/.block
<!DOCTYPE html>
<meta charset="utf-8">
<style>
.link {
stroke: #000;
}
.node {
fill: #ccc;
@wyaeld
wyaeld / config.ru.rb
Created January 19, 2012 23:32 — forked from brianmario/config.ru.rb
minimal rails3 app
# minimal rails3 app
require 'action_controller'
Router = ActionDispatch::Routing::RouteSet.new
Router.draw do
root :to => 'site#index'
end
class SiteController < ActionController::Metal
@wyaeld
wyaeld / person_test.rb
Created October 27, 2011 09:46 — forked from tenderlove/person_test.rb
Use minitest/spec with Rails 3
require 'test_helper'
require 'minitest/autorun'
module Tenderlove
class Spec < MiniTest::Spec
include ActiveSupport::Testing::SetupAndTeardown
include ActiveRecord::TestFixtures
alias :method_name :__name__ if defined? :__name__
self.fixture_path = File.join(Rails.root, 'test', 'fixtures')