This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"2011-10-07 20:40:35Z": {"gitlog": {"mem": 0.0, "cpu": 0.0, "exec": [{"duration": "0:00", "command": "svlogd"}]}, "marco": {"mem": 0.2, "cpu": 0.0, "exec": [{"duration": "0:00", "command": "sshd:"}, {"duration": "0:00", "command": "-bash"}]}, "seacrow": {"mem": 6.3, "cpu": 0.1, "exec": [{"duration": "0:46", "command": "Rails:"}]}, "root": {"mem": 3.4000000000000004, "cpu": 0.0, "exec": [{"duration": "0:03", "command": "init"}, {"duration": "0:00", "command": "/usr/sbin/vsftpd"}, {"duration": "0:06", "command": "/usr/sbin/sshd"}, {"duration": "0:01", "command": "runsvdir"}, {"duration": "0:00", "command": "runsv"}, {"duration": "0:00", "command": "cron"}, {"duration": "0:00", "command": "/usr/sbin/courierlogger"}, {"duration": "0:00", "command": "/usr/lib/courier/courier-authlib/authdaemond"}, {"duration": "0:00", "command": "/usr/sbin/courierlogger"}, {"duration": "0:00", "command": "/usr/sbin/couriertcpd"}, {"duration": "0:00", "command": "/usr/lib/courier/courier-authlib/authdaemond"}, {"duration": "0:00", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@dagobah:/opt/usagelog# git remote add upstream git://github.com/sfstpala/Usage-Log.git | |
root@dagobah:/opt/usagelog# git pull upstream master | |
remote: Counting objects: 8, done. | |
remote: Compressing objects: 100% (2/2), done. | |
remote: Total 4 (delta 2), reused 4 (delta 2) | |
Unpacking objects: 100% (4/4), done. | |
From git://github.com/sfstpala/Usage-Log | |
* [new branch] master -> upstream/master | |
Updating 579e48e..0bb9624 | |
Fast-forward |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json_rpc | |
import subprocess | |
import cherrypy | |
import os | |
import json | |
class Module (object): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
juju-log "Adding Canonical Partner repository" | |
RELEASE_CODE=`lsb_release -sc` | |
add-apt-repository "deb http://archive.canonical.com/ ${RELEASE_CODE} partner" | |
apt-get update | |
apt-get -y install -qq --no-install-recommends debconf-utils | |
echo "sun-java6-plugin shared/accepted-sun-dlj-v1-1 boolean true" | debconf-set-selections |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Bar bar bar! | |
Drink Drink Drink! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
debconf-set-selections tpl/debconf-selections |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Minecraft upstart | |
# this script will start/stop Minecraft | |
description "Minecraft Server" | |
version "1.0" | |
author "Marco Ceppi" | |
env CPU_COUNT=1 | |
env JAVA_ARGS="-Xmx1024M -Xms1024M -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalPacing -XX:+AggressiveOpts" | |
env LOG="server.log" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
session_start(); | |
$si_prefix = array( 'B', 'KB', 'MB', 'GB', 'TB', 'EB', 'ZB', 'YB' ); | |
$base = 1024; | |
if( !is_array($_SESSION['speed']) ) | |
{ | |
$_SESSION['speed'] = array('updated' => time(), 'old' => file_get_contents('/sys/class/net/eth0/statistics/rx_bytes')); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/lib/redcarpet/render/gitlab_html.rb | |
+++ b/lib/redcarpet/render/gitlab_html.rb | |
@@ -3,7 +3,7 @@ class Redcarpet::Render::GitlabHTML < Redcarpet::Render::HTML | |
if Pygments::Lexer.find(language) | |
Pygments.highlight(code, :lexer => language, :options => {:encoding => 'utf-8'}) | |
else | |
- Pygments.highlight(code, :options => {:encoding => 'utf-8'}) | |
+ Pygments.highlight(code, :lexer => 'bash', :options => {:encoding => 'utf-8'}) | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Storage Engine Components | |
* | |
* @author Marco Ceppi <marco@ceppi.net> | |
* @package Amulet | |
* @subpackage Model | |
*/ | |
/** |