https://wiki.ubuntu.com/SergeHallyn_libvirtlxc
apt-get install -y libvirt-bin lxc
lxc-create -t ubuntu -n o1
wget http://people.canonical.com/~serge/o1.xml
virsh -c lxc:// define o1.xml
virsh -c lxc:// start o1
virsh -c lxc:// console o1
var HTML5Audio = true; | |
if (HTML5Audio) { | |
Campfire.HTML5Audio = Class.create({ | |
initialize: function(chat) { | |
this.chat = chat; | |
var messages = this.chat.transcript.messages; | |
for(var i = 0; i < messages.length; i++) { | |
this.detectAudio(messages[i], false); | |
} |
var pending = function(test, fn) { | |
var assert = require('assert'); | |
assert.done = function() { | |
test.done(); | |
}; | |
var failed = false; | |
try { | |
fn(assert); | |
} catch (e) { |
/* | |
* Copyright (c) 2011 Justin Tulloss | |
* Copyright (c) 2010 Justin Tulloss | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy | |
* of this software and associated documentation files (the "Software"), to deal | |
* in the Software without restriction, including without limitation the rights | |
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
* copies of the Software, and to permit persons to whom the Software is |
"use strict"; | |
var fs = require("fs"), | |
https = require("https"), | |
url = require("url"), | |
zlib = require("zlib"); | |
/** | |
* Process HTTP responses. Handle compressed streams and convert to objects as | |
* appropriate. |
<!DOCTYPE html> | |
<html> | |
<head> | |
<style type="text/css"> | |
#map { | |
width: 1000px; | |
height: 600px; | |
} | |
path { |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Water</title> | |
<style type="text/css"> | |
.sparkline path.line { | |
fill: none; | |
stroke: #999; | |
} |
7640,PST,'FLOW, RIVER DISCHARGE (cfs)' | |
20111231,2300,624 | |
20111231,2315,646 | |
20111231,2330,708 | |
20111231,2345,668 | |
20120101,0000,547 | |
20120101,0015,479 | |
20120101,0030,391 | |
20120101,0045,304 | |
20120101,0100,291 |
"use strict"; | |
var d3 = require("d3"); | |
var WORKERS = 5; | |
var worker = function(complete) { | |
var doWork = function() { | |
return done(); | |
}; |
https://wiki.ubuntu.com/SergeHallyn_libvirtlxc
apt-get install -y libvirt-bin lxc
lxc-create -t ubuntu -n o1
wget http://people.canonical.com/~serge/o1.xml
virsh -c lxc:// define o1.xml
virsh -c lxc:// start o1
virsh -c lxc:// console o1
# Get the EC2 region from an instance, because ec2metadata only includes the availability zone (which is close, but not close enough). | |
REGION=$(curl http://169.254.169.254/latest/dynamic/instance-identity/document|grep region|awk -F\" '{print $4}') | |
# extended ec2metadata, including tags (requires an IAM role with ec2:DescribeTags) | |
list_instances -r $REGION -H T:Name,ID,Hostname,State -f "instance-id=$(ec2metadata --instance-id)" | |
export HOST=$(list_instances -r $REGION -H T:Name,ID,Hostname,State -f "instance-id=$(ec2metadata --instance-id)" | grep running | awk '{print $1}') |