Skip to content

Instantly share code, notes, and snippets.

View alexbilbie's full-sized avatar
👋

Alex Bilbie alexbilbie

👋
View GitHub Profile
---
# ^^^ YAML documents must begin with the document separator "---"
#
#### Example docblock, I like to put a descriptive comment at the top of my
#### playbooks.
#
# Overview: Playbook to bootstrap a new host for configuration management.
# Applies to: production
# Description:
# Ensures that a host is configured for management with Ansible.
@alexbilbie
alexbilbie / jenkins.md
Created August 13, 2013 14:36 — forked from skl/jenkins.md

Creating a new Jenkins Server

First step, make sure java -version reports 1.6 or higher. If the command fails or the version isn't high enough, download the latest version of Java JDK from Oracle (http://www.oracle.com/technetwork/java/javase/downloads/index.html) (jdk-7u25-linux-x64.tar.gz at the time of writing) - a quick uname -m will let you know if you need the 32 or 64bit version. Installation instructions are available here (http://docs.oracle.com/javase/7/docs/webnotes/install/linux/linux-jdk.html#install-64).

My preference is to extract these to /usr/local and then ln -s /usr/local/jdk1.7.0_25 /usr/local/jdk.

Add /usr/local/jdk/bin to your $PATH.

Download the latest Jenkins WAR (1.519 currently) file from http://mirrors.jenkins-ci.org/war/latest/.

#!/usr/local/bin/bash
COMPASS="/usr/local/bin/compass"
case "$1" in
   ""|start)
   echo "Starting compass watch..."
   if [ -f ./cwatch.pid ]
then
echo "Sorry, but compass is already watching this folder..."
@alexbilbie
alexbilbie / paths.php
Created March 30, 2013 13:54
Laravel 3 autoload Composer
# Add after $paths['public']
// --------------------------------------------------------------
// The path to the composer vendors directory.
// --------------------------------------------------------------
$paths['composer'] = 'vendor';
$regions = [];
$potentialRegion = 0;
function adjacentPixelIsBlack($x, $y)
{
if ( ! isset($matrix[$x][$y+1]))
{
return false;
}
Holly Madison has settled on a name for her newborn daughter - and it's very colourful indeed.
The 33-year-old former Playboy model and her boyfriend, Pasquale Rotella, 38, have called the little girl Rainbow Aurora Rotella.
'I wanted to give my daughter a unique name,' she told E! on Friday.
'So happy': New mother Holly Madison shared this picture of herself and partner Pasquale Rotella on Friday
'Growing up, there was a girl in my school named Rainbow and I was so envious of that name. I thought it was so pretty and unique'
@alexbilbie
alexbilbie / gist:5101426
Created March 6, 2013 17:50
Implicit grant
<?php
/**
* OAuth 2.0 implicit grant
*
* @package lncd/oauth2
* @author Alex Bilbie <hello@alexbilbie.com>
* @copyright Copyright (c) 2013 University of Lincoln
* @license http://mit-license.org/
* @link http://github.com/lncd/oauth2
*/
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2" xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom">
<Document>
<name>Alford and Sutton ED.kml</name>
<Style id="failed">
<LineStyle>
<color>ffff0000</color>
</LineStyle>
<PolyStyle>
<color>40ff0000</color>
@alexbilbie
alexbilbie / gist:4171008
Created November 29, 2012 18:37
Weird ruby error
~/.rvm/gems/ruby-1.9.3-p327/gems/jekyll-0.11.2/bin/jekyll --server --no-auto
Configuration from /Users/alexbilbie/Github/alexbilbie.com/_config.yml
Building site: /Users/alexbilbie/Github/alexbilbie.com -> /Users/alexbilbie/Github/alexbilbie.com/_site
/Users/alexbilbie/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/psych.rb:203:in `parse': (<unknown>): found unknown escape character while parsing a quoted scalar at line 4 column 8 (Psych::SyntaxError)
from /Users/alexbilbie/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/psych.rb:203:in `parse_stream'
from /Users/alexbilbie/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/psych.rb:151:in `parse'
from /Users/alexbilbie/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/psych.rb:127:in `load'
from /Users/alexbilbie/.rvm/gems/ruby-1.9.3-p327/gems/jekyll-0.11.2/lib/jekyll/convertible.rb:33:in `read_yaml'
from /Users/alexbilbie/.rvm/gems/ruby-1.9.3-p327/gems/jekyll-0.11.2/lib/jekyll/post.rb:39:in `initialize'
@alexbilbie
alexbilbie / gist:4125156
Created November 21, 2012 14:42
Lincoln sites
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2" xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom">
<Folder>
<name>Temporary Places</name>
<open>1</open>
<Document>
<name>chad.kml</name>
<Style id="sh_ylw-pushpin">
<IconStyle>
<scale>1.3</scale>