Skip to content

Instantly share code, notes, and snippets.

View davidpelaez's full-sized avatar

David Pelaez davidpelaez

  • Vlipco
  • Bogota, Colombia
View GitHub Profile
@davidpelaez
davidpelaez / gearls.sh
Created June 12, 2014 09:00
shell script to list all geard installed containers
#!/bin/bash
cd /var/lib/containers/units
units=$(find . -maxdepth 2 | grep '.service' | awk -F'/' '{print $3}')
keys=( LoadState ActiveState SubState UnitFileState )
result=""
for unit in $units; do
@davidpelaez
davidpelaez / .uri
Last active August 29, 2015 14:01
process error
/Volumes/Low/David/.sm/exts/versions/test/head
@davidpelaez
davidpelaez / geard_notes.txt
Created April 20, 2014 10:17
My notes to understandig the Geard code at the time of writing https://github.com/openshift/geard
To Install
=========
Based on contrib/bootstrap-dev-vm:
- Dependencies first
- Then build
- Link the unit
- Then enable the unit
@davidpelaez
davidpelaez / enabled
Created March 11, 2014 06:22
Must use systemd at least 208
1
GIT
remote: https://github.com/Vlipco/glider.git
revision: bdaf93f1284273a3e8770cbdce01557adcc11b53
specs:
glider (0.2.0)
activesupport
aws-sdk
json
GEM
# A sample Guardfile
# More info at https://github.com/guard/guard#readme
require "active_support/inflector"
guard :rspec, cli:'--color --format documentation', spring: true do
watch(%r{^spec/.+_spec\.rb$})
# watch the factories
watch(%r{^spec/factories/(.+)\.rb$}) do |m|
%W[
spec/models/#{ActiveSupport::Inflector.singularize m[1]}_spec.rb
// Set up a simple object to use as "context"
var context = { foo: "bar" };
// A function that uses a reference to a variable called "foo"
// on the "this" context.
function returnFoo () {
return this.foo;
}
// This variable does not exist on scope, so is undefined.
@davidpelaez
davidpelaez / jade_compile.rb
Created November 12, 2013 03:26
Shows how to compile jade from ruby without node available in the system using binary gem the ruby racer, a V8 port for Ruby.
# Assuming you have jade's browserified version:
# as of the time of writing lives in: https://github.com/visionmedia/jade/blob/master/jade.js
#!/usr/bin/env ruby
puts "Compiling hellow world, expected output is <h1>Hellow world</h1>"
require 'rubygems'
require 'v8' #therubyracer
@davidpelaez
davidpelaez / index.html
Created November 1, 2013 18:09
trying to compile jade using therubyracer
<html>
<head>
<script src='jade.js'></script>
</head>
<body>
done.
</body>
</html>
class SimpleWorkflowAPI
extend SimplerWorkflow::ParentProcess
log_level Logger::DEBUG
workers 1
domain = SimplerWorkflow::Domain.domains "my_ops"