Sidnei da Silva sidnei

View lxc-thin-provisioning
1 2 3 4 5 6 7 8 9
$ sudo fallocate -l 6G /tmp/lxc
$ sudo losetup -f /tmp/lxc
$ sudo pvcreate /dev/loop0
$ sudo vgcreate lxc /dev/loop0
 
$ sudo lvcreate -l 95%FREE --type thin-pool --thinpool lxc lxc
$ sudo lvs
LV VG Attr LSize Pool Origin Data% Move Log Copy% Convert
lxc lxc twi-a-tz- 5.70g 0.00
View gist:7041338
1 2 3 4 5 6 7 8 9
# Using lvm thin provisioning, per https://github.com/lxc/lxc/pull/67
 
# First we create a volume group to hold the thin pool
 
$ sudo vgcreate lxc /dev/sde3
 
# Then create a thin-pool named 'tp' within that volume group
 
$ sudo lvcreate -l 90%VG --type thin-pool --thinpool tp lxc
View status.yaml
1 2 3 4 5 6 7 8 9 10
machines:
0:
agent-state: running
dns-name: 10.55.63.161
instance-id: 16104caa-c963-45a0-9be7-03c7be6cd631
instance-state: running
1:
agent-state: running
dns-name: 10.55.63.54
instance-id: e06c6bdd-80ab-47d3-973c-18bf5c27a0a0
View gist:3701493
1 2 3 4 5 6 7 8 9
import os
import sys
import select
import time
import fcntl
#from multiprocessing import Pipe
from billiard import Pipe
 
parent, child = Pipe()
View gist:1327886
View node-detach.js
1 2 3 4 5 6 7 8 9 10
// Works. Logs 'click'.
YUI().use("event", "node", "node-event-simulate", function(Y){
var node = Y.one(".item");
node.on("foo|click", function() {
console.log("clicked");
});
node.simulate("click");
node.detach("foo|click");
node.simulate("click");
});
View example.css
1 2 3 4 5 6 7 8 9 10
/* Overlay Look/Feel */
.yui3-overlay-content {
padding:2px;
border:1px solid #000;
background-color:#aaa;
font-size:93%;
}
 
.yui3-overlay-content .yui3-widget-hd {
font-weight:bold;
View gist:377020
1 2 3 4 5 6 7 8 9 10
// Copyright 2005-2010 Canonical Limited. All rights reserved.
 
var LANDSCAPE_YUI_CONFIG = {
filter: "min",
base: "/static/yui/"
};
 
 
// If Javascript debugging is enabled, configure the YUI loader to use
// the debug versions of the Javascript files.
Something went wrong with that request. Please try again.