Skip to content

Instantly share code, notes, and snippets.


Kevin Carmody skinofstars

View GitHub Profile
skinofstars / deploy.yml
Last active Mar 17, 2016
super basic deploy playbook
View deploy.yml
# ansible-playbook -i hosts -l production deploy.yml
- hosts: production
app_root: '/home/ubuntu/app'
app_public: "{{app_root}}/public_html"
- synchronize: src=blog dest={{app_public}}/
- copy: src=foobar.txt dest={{app_root}}/
skinofstars / .htaccess
Last active Aug 29, 2015
Some casual .htaccess gzip action
View .htaccess
# normal rules before this
Options -Indexes
Header unset ETag
FileETag None
skinofstars / packer.json
Created Mar 18, 2015
Ansible packer.json example
View packer.json
"variables": {
"aws_access_key": "",
"aws_secret_key": ""
"builders": [{
"type": "amazon-ebs",
"access_key": "{{user `aws_access_key`}}",
"secret_key": "{{user `aws_secret_key`}}",
"region": "eu-west-1",
View gist:d5837883b54098970b53
### Keybase proof
I hereby claim:
* I am skinofstars on github.
* I am skinofstars ( on keybase.
* I have a public key whose fingerprint is 969A 048C 6746 A52D 13C7 9267 AA1B 33F6 6ADB 691F
To claim this, I am signing this object:
# every time, i forget how to pull submodules on a project where i forgot to do a --recursive clone/pull
git submodule init
git submodule update
skinofstars / application_routes.js
Created Dec 11, 2014
Ember rollback unsaved changes on navigation
View application_routes.js
// Extend from this for a user to get a notification for unsaved model changes
// and rollback the model if they choose to navigate away.
Ember.DSModelRoute = Ember.Route.extend({
deactivate: function() {
var model = this.get('controller.model');
if (model.get('isNew')) {
skinofstars / rock_paper_scissors.js
Last active Aug 29, 2015
BrumJS - rock paper scissors
View rock_paper_scissors.js
// BrumJS - Rock Paper Scissors bots game
// water beats dynamite
// dynamite beats everything (max 5 use)
// for keeping track of some stuff
var game = {}; = {};
skinofstars / jobs_new_controller.js
Last active Aug 29, 2015
ember data not populating model errors
View jobs_new_controller.js
// using ActiveModelAdapter
App.ApplicationAdapter = DS.ActiveModelAdapter.extend();
// simple model
App.Job = DS.Model.extend({
external_ref: DS.attr("string")
// creating a new Job.
App.JobsNewController = Ember.Controller.extend({
View gist:9d932e2f8cb1b07423c4
# working folder. world store, etc
cd /home/skinofstars/mc
rsync --rsh='ssh -p25561' -avz* world_folder
cd world_folder
# so anyone can read the log
skinofstars / lean.rb
Created Jul 16, 2014
lean kata.... err, less lean
View lean.rb
# pommes, mele same as apples
@shop = {
apples: 100,
cherries: 75,
bananas: 150,
pommes: 100,
mele: 100