Skip to content

Instantly share code, notes, and snippets.

# Update, upgrade and install development tools:
apt-get update
apt-get -y upgrade
apt-get -y install build-essential
apt-get -y install git-core
# Install rbenv
git clone git://github.com/sstephenson/rbenv.git /usr/local/rbenv
# Add rbenv to the path:
@keymon
keymon / README.md
Last active August 29, 2015 14:26
GNU plot ab performance and CPU for a tsuru installation

AB benchmark and plotting

Small script to execute a apache benchmark ab from one host to other.

The scripts are designed for benchmark tsuru routers, and compare between hipache+nginx vs. vulcand.

It will gather metrics of request time and CPU in the target so they can be later plot using gnuplot.

@dcarley
dcarley / mcollective-plugins.spec
Created May 5, 2011 13:34
RPM SPEC for bundling up some of the official mcollective plugins.
%define giturl git://github.com/puppetlabs/mcollective-plugins.git
%define gitrev d9305be
%define gituser puppetlabs
%define plugindir %{_libexecdir}/mcollective/mcollective
%define agents puppetd nettest service package filemgr nrpe puppetca puppetral
Name : mcollective-plugins
Version : 0.0.1
Release : 3.%{gitrev}
@babysnakes
babysnakes / deploy_via_methods.rb
Created January 4, 2012 05:44
Trying to create rolling deploy via capistrano.
role :servers, "server1", "server2"
set :user, 'ubuntu'
def stop_load_balancer
run "echo service registerelb stop"
end
def start_load_balancer
run "echo service registerelb start"
end
@actionjack
actionjack / tomcat.sh
Created September 20, 2012 14:06 — forked from valotas/tomcat.sh
Tomcat init.d script
#!/bin/bash
#
# tomcat7 This shell script takes care of starting and stopping Tomcat
#
# chkconfig: - 80 20
#
### BEGIN INIT INFO
# Provides: tomcat7
# Required-Start: $network $syslog
# Required-Stop: $network $syslog
@actionjack
actionjack / concourse-example-tasks.md
Created November 25, 2015 11:42 — forked from drnic/concourse-example-tasks.md
A simple concourse example task - fork and try anything

Concourse Tutorial - Example Tasks

This gist includes some https://concourse.ci job tasks

  • hello-world.yml - displays "hello world"
  • display-other-task.yml - uses this task as a resource itself and displays the hello-world.yml YAML; assumes that the gist is available in the concourse pipeline as resource-gist.
  • display-other-task-renamed-resource-input.yml - is like the task above, but assumes the resource is now named gist rather than resource-gist
@davidillsley
davidillsley / gist:7481319
Last active December 28, 2015 09:48
Accessing EMC Atmos using S3 tooling

Accessing EMC Atmos using S3 tooling

There are loads of tools out there built around the AWS APIs. In response to that, some software comes with an AWS compatibility layer. One of them is EMC Atmos.

There's a surprising lack of documentation on how to actually use this compatibility. The best I could find is the "EMC® Atmos™ Version 2.1 Programmer’s Guide P/N 300-013-493 REV 01". However, all it does it tell you that the S3 compatibility is hosted on a different port, and which operations are supported. It doesn't give any hints on how to get any tools working.

The main gotcha seems to be that the S3 API has both a path and DNS based way of accessing buckets. It's important to use the path based mechanism.

JetS3t

@EHadoux
EHadoux / Readme.md
Last active May 18, 2016 10:07
Sonar Widget for Dashing

Description

This is a dashing widget intended to show metrics from a sonar repository.

Usage

This widget currently uses the list widget as a view. You just have to add this snippet to your dashboard:

@jaredcurtis
jaredcurtis / gist:1895347
Created February 23, 2012 22:14
sorted hash in puppet templates
databases => {
'default' =>
{
'ENGINE' => 'postgresql_psycopg2',
'NAME' => 'defaultdb',
'HOST' => '2.2.2.2.2',
'USER' => 'username',
'PASSWORD' => 'secretinfo',
'OPTIONS' =>
{
@crhan
crhan / operating_system.rb
Last active September 12, 2016 15:10
rbenv.spec
module Gem
class << self
##
# Returns full path of previous but one directory of dir in path
# E.g. for '/usr/share/ruby', 'ruby', it returns '/usr'
def previous_but_one_dir_to(path, dir)
split_path = path.split(File::SEPARATOR)
File.join(split_path.take_while { |one_dir| one_dir !~ /^#{dir}$/ }[0..-2])