Skip to content

Instantly share code, notes, and snippets.

View damm's full-sized avatar

Scott M. Likens damm

  • Seattle, Washington USA
View GitHub Profile
require 'rubygems'
require 'merb-core'
require 'chef'
Chef::Config.from_file(File.join("/etc", "chef", "server.rb"))
Merb::Config.setup(:merb_root => File.expand_path(File.dirname(__FILE__)),
:environment => ENV['RACK_ENV'],
:fork_for_class_load => false,
:init_file => File.dirname(__FILE__) / "config/init.rb")
identity : nanite-54af7fd8-fae1-4dd4-b7bc-2c5ca3696541
load : 0.343333333333333
services : ["/index/add", "/index/delete", "/index/commit", "/index/optimize"]
tags: [nil]
apt-get install build-essential
cd /usr/src;wget "ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.6-p368.tar.bz2" && tar jxfv ruby-1.8.6-p368.tar.bz2
cd ruby-1.8.6-p368
./configure --prefix=/usr --enable-shared --enable-pthread
make
make install
<%- @app_servers.each do |app| %>
server <%= app['hostname'] %> <%= app['ipaddress'] %>:80
<%- end %>
15:28 <Damm> sigmonsays, http://seattlerb.rubyforge.org/SyslogLogger/
15:28 <holoway> sigmonsays: in theory, you can drop in that SyslogLogger for Chef::Log.logger
15:29 <holoway> sigmonsays: something like Chef::Log.logger = SyslogLogger.new("chef")
15:31 >>> bleything <3 SyslogLogger
@damm
damm / .zshrc
Created October 24, 2009 23:16
# Joshua Timberman <joshua@housepub.org>
# My .zshrc, modified from:
#
# $Id: .zshrc,v 1.1 2006/04/19 22:08:04 adam Exp $
#
# Adam's zshrc - <adam@stalecoffee.org>
#
# Stolen entirely from --
#
# Andy's zshrc <william.a@carrel.org>
#
# Cookbook Name:: scaffold
# Recipe:: network
#
# Copyright 2009, IGN Entertainment
#
# All rights reserved - Do Not Redistribute
#
execute "set_hostname" do
@damm
damm / .zshrc
Created October 22, 2009 05:34
# Joshua Timberman <joshua@housepub.org>
# My .zshrc, modified from:
#
# $Id: .zshrc,v 1.1 2006/04/19 22:08:04 adam Exp $
#
# Adam's zshrc - <adam@stalecoffee.org>
#
# Stolen entirely from --
#
# Andy's zshrc <william.a@carrel.org>
remote_file "/usr/src/nagios-3.2.0.tar.gz" do
source "http://prdownloads.sourceforge.net/sourceforge/nagios/nagios-3.2.0.tar.gz"
checksum "7cbf35ba0319f24fa085982c038437c4515003b27863c4897dc86b197a50a5e7"
not_if { FileTest.exists?("/usr/src/nagios-3.2.0.tar.gz") }
end
execute "un-unarchive nagios" do
command "cd /usr/src;tar zxfv nagios-3.2.0.tar.gz"
only_if { FileTest.exists?("/usr/src/nagios-3.2.0.tar.gz") }
not_if { FileTest.directory?("/usr/src/nagios-3.2.0") }
@damm
damm / default.rb
Created October 16, 2009 20:15 — forked from adamhjk/default.rb
#
# Cookbook Name:: users
# Recipe:: default
#
# Copyright 2009, Opscode, Inc
package "libshadow-ruby1.8"
group "sysadmin" do
gid 4242