Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
# Colours picked from https://robinpowered.com/blog/best-practice-system-for-organizing-and-tagging-github-issues/
###
# Label definitions
###
declare -A LABELS
# Platform
haproxy.conf
============
frontend spdy
mode tcp
bind xxx.xxx.xxx.xxx:443 ssl crt /etc/haproxy/ssl.pem crt /etc/haproxy/certs.d npn spdy/3.1,http/1.1 ciphers AES256+EECDH:AES256+EDH:AES128+EDH:EECDH:!aNULL:!eNULL:!LOW:!DES:!3DES:!RC4; no-sslv3
option tcplog
log global
# route to nginx
# Script to test stemming for ElasticSearch. Working now!!
# Reference: http://stackoverflow.com/questions/4981001/why-elasticsearch-is-not-finding-my-term
require 'rubygems'
require 'net/http'
require 'yaml'
require 'json'
# kill the index
delete = Net::HTTP::Delete.new("/willindex")
<span class="rating">
<input id="star-5" name="radioradio" type="radio" value="5"><label for="star-5"></label>
<input id="star-4" name="radioradio" type="radio" value="4"><label for="star-4"></label>
<input id="star-3" name="radioradio" type="radio" value="3"><label for="star-3"></label>
<input id="star-2" name="radioradio" type="radio" value="2"><label for="star-2"></label>
<input id="star-1" name="radioradio" type="radio" value="1"><label for="star-1"></label>
</span>
%icon {
font-family: $icon-font; //set as a variable - it's whatever your icon font name is
speak: none;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;
-webkit-font-smoothing: antialiased;
}
// stars.scss
// compiles to stars.css
$starWidth: 44px;
$starOffset: 0 -43px;
$numStars: 5;
$steps: 2;
$total: $numStars * $steps;
@mixin filled($n: 0) {
<div class="empty">
<div class="filled"></div>
</div>
<!-- stars.html.erb -->
<div class="stars empty">
<div class="stars filled"></div>
</div>
<!--
This way you can namespace your selectors.
The markup isn't as pretty, but you can
sleep soundly knowing other developers
<!-- stars.html.erb -->
<div class="stars empty">
<div class="stars filled_<%= @obj.rating %>"></div>
</div>
#!/bin/bash
# bin/elb-describe-lbs | awk '{print $2}' | xargs -n1 elb-set-secure-policy.sh
ELB=$1
echo "Setting Policy on Load Balancer $1"
bin/elb-create-lb-policy $ELB \
--policy-type SSLNegotiationPolicyType \
--policy-name elb-secure-ssl \