-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove passenger support from rails recipe. update versions. add kvm,…
… dhcpd, nagios plugins, fcgiwrap.
- Loading branch information
Showing
101 changed files
with
7,468 additions
and
379 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
default.apache[:user] = "www-data" | ||
default.apache[:binary] = "/usr/sbin/apache2" | ||
default.apache[:icondir] = "/usr/share/apache2/icons" | ||
default.apache[:version] = "2.2.9-7ubuntu3.5" | ||
default.apache[:version] = "2.2.12-1ubuntu2" | ||
|
||
default.apache[:listen_ports] = ["80"] | ||
default.apache[:contact] = "[email protected]" | ||
|
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,13 @@ | ||
remote_file "/etc/apt/packages.gpg" do | ||
source "packages.gpg" | ||
owner "root" | ||
group "root" | ||
mode 0644 | ||
end | ||
|
||
remote_file "/etc/apt/sources.list" do | ||
source "sources.list.#{node[:domain].split(".").first}" | ||
owner "root" | ||
group "root" | ||
mode 0644 | ||
not_if { node[:domain] == 'localdomain' || node[:domain] == 'ubuntu' } | ||
end | ||
|
||
%w{/var/cache/local /var/cache/local/preseeding}.each do |dirname| | ||
directory dirname do | ||
if @node[:datacenter] | ||
remote_file "/etc/apt/sources.list" do | ||
source "sources.list.#{@node[:datacenter]}" | ||
owner "root" | ||
group "root" | ||
mode 0644 | ||
action :create | ||
mode 00644 | ||
end | ||
end | ||
|
||
execute "apt-key-add" do | ||
command "/usr/bin/apt-key add /etc/apt/packages.gpg" | ||
only_if "test `/usr/bin/apt-key list | grep -c [email protected]` -eq 0" | ||
end | ||
|
||
execute "apt-get-update" do | ||
command "apt-get update" | ||
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
default.bluepill[:bin] = languages[:ruby][:bin_dir] + "/bluepill" | ||
default.bluepill[:bin] = node[:languages][:ruby][:bin_dir] + "/bluepill" | ||
default.bluepill[:config_dir] = "/etc/bluepill" | ||
default.bluepill[:log_dir] = "/var/log/bluepill" | ||
default.bluepill[:pid_dir] = "/var/run/bluepill" | ||
bluepill[:version] = "0.0.37" | ||
bluepill[:version] = "0.0.37" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
set[:bundler][:version] = '0.9.13' | ||
set[:bundler][:version] = '0.9.24' |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
default.chef[:server_version] = "0.8.10" | ||
default.chef[:server_path] = "#{languages[:ruby][:gems_dir]}/gems/chef-server-#{chef[:server_version]}" | ||
default.chef[:server_api_path] = "#{languages[:ruby][:gems_dir]}/gems/chef-server-api-#{chef[:server_version]}" | ||
default.chef[:server_webui_path] = "#{languages[:ruby][:gems_dir]}/gems/chef-server-webui-#{chef[:server_version]}" | ||
default.chef[:webui_default_password] = '7bc318032e' | ||
default.chef[:server_version] = "0.8.11" | ||
default.chef[:server_path] = "#{node[:languages][:ruby][:gems_dir]}/gems/chef-server-#{chef[:server_version]}" | ||
default.chef[:server_api_path] = "#{node[:languages][:ruby][:gems_dir]}/gems/chef-server-api-#{chef[:server_version]}" | ||
default.chef[:server_webui_path] = "#{node[:languages][:ruby][:gems_dir]}/gems/chef-server-webui-#{chef[:server_version]}" | ||
default.chef[:webui_default_password] = '7bc318032e' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/bin/sh | ||
PATH=/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin<% if @node[:languages][:ruby][:gems_dir] %>:<%= @node[:languages][:ruby][:gems_dir] %>/bin<% end -%> | ||
exec 2>&1 | ||
exec /usr/bin/env chef-client -i <%= @node[:bootstrap][:chef][:client_interval] %> -s <%= @node[:bootstrap][:chef][:client_splay] %> <% if @node[:bootstrap][:chef][:client_log] != "STDOUT" then -%>-L <%= @node[:bootstrap][:chef][:client_log] %><% end -%> | ||
exec /usr/bin/env chef-client -i <%= @node[:chef][:client_interval] %> -s <%= @node[:chef][:client_splay] %> <% if @node[:chef][:client_log] != "STDOUT" then -%>-L <%= @node[:chef][:client_log] %><% 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
default.dhcpd[:interfaces] = [ 'eth0' ] | ||
default.dhcpd[:tftp_server] = "10.0.0.1" | ||
default.dhcpd[:gateway] = "10.0.0.1" | ||
default.dhcpd[:netmask] = "255.255.255.0" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
maintainer "37signals" | ||
maintainer_email "[email protected]" | ||
description "Configures DHCP Daemon" | ||
version "0.1" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# | ||
# Cookbook Name:: dhcpd | ||
# Recipe:: default | ||
# | ||
# Copyright 2010, 37signals | ||
# | ||
# All rights reserved - Do Not Redistribute | ||
# | ||
|
||
package "dhcp3-server" | ||
service "dhcp3-server" | ||
|
||
template "/etc/default/dhcp3-server" do | ||
source "dhcp3-server.default.erb" | ||
owner "root" | ||
group "root" | ||
mode 0644 | ||
notifies(:restart, resources(:service => "dhcp3-server")) | ||
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Defaults for dhcp initscript | ||
# sourced by /etc/init.d/dhcp | ||
# installed at /etc/default/dhcp3-server by the maintainer scripts | ||
|
||
# | ||
# This is a POSIX shell fragment | ||
# | ||
|
||
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests? | ||
# Separate multiple interfaces with spaces, e.g. "eth0 eth1". | ||
INTERFACES="<%= @node[:dhcpd][:interfaces ].join(' ') %>" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,128 @@ | ||
# | ||
# Sample configuration file for ISC dhcpd for Debian | ||
# | ||
# Attention: If /etc/ltsp/dhcpd.conf exists, that will be used as | ||
# configuration file instead of this file. | ||
# | ||
# $Id: dhcpd.conf,v 1.1.1.1 2002/05/21 00:07:44 peloy Exp $ | ||
# | ||
|
||
# The ddns-updates-style parameter controls whether or not the server will | ||
# attempt to do a DNS update when a lease is confirmed. We default to the | ||
# behavior of the version 2 packages ('none', since DHCP v2 didn't | ||
# have support for DDNS.) | ||
ddns-update-style none; | ||
|
||
# option definitions common to all supported networks... | ||
option domain-name "<%= node[:domain] %>"; | ||
option domain-name-servers <%= node[:nameservers].join(',') %> | ||
|
||
default-lease-time 600; | ||
max-lease-time 7200; | ||
|
||
# If this DHCP server is the official DHCP server for the local | ||
# network, the authoritative directive should be uncommented. | ||
#authoritative; | ||
|
||
# Use this to send dhcp log messages to a different log file (you also | ||
# have to hack syslog.conf to complete the redirection). | ||
log-facility local7; | ||
|
||
# No service will be given on this subnet, but declaring it helps the | ||
# DHCP server to understand the network topology. | ||
|
||
#subnet 10.152.187.0 netmask 255.255.255.0 { | ||
#} | ||
|
||
# This is a very basic subnet declaration. | ||
|
||
#subnet 10.254.239.0 netmask 255.255.255.224 { | ||
# range 10.254.239.10 10.254.239.20; | ||
# option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org; | ||
#} | ||
|
||
# This declaration allows BOOTP clients to get dynamic addresses, | ||
# which we don't really recommend. | ||
|
||
#subnet 10.254.239.32 netmask 255.255.255.224 { | ||
# range dynamic-bootp 10.254.239.40 10.254.239.60; | ||
# option broadcast-address 10.254.239.31; | ||
# option routers rtr-239-32-1.example.org; | ||
#} | ||
|
||
# A slightly different configuration for an internal subnet. | ||
#subnet 10.5.5.0 netmask 255.255.255.224 { | ||
# range 10.5.5.26 10.5.5.30; | ||
# option domain-name-servers ns1.internal.example.org; | ||
# option domain-name "internal.example.org"; | ||
# option routers 10.5.5.1; | ||
# option broadcast-address 10.5.5.31; | ||
# default-lease-time 600; | ||
# max-lease-time 7200; | ||
#} | ||
|
||
# Hosts which require special configuration options can be listed in | ||
# host statements. If no address is specified, the address will be | ||
# allocated dynamically (if possible), but the host-specific information | ||
# will still come from the host declaration. | ||
|
||
#host passacaglia { | ||
# hardware ethernet 0:0:c0:5d:bd:95; | ||
# filename "vmunix.passacaglia"; | ||
# server-name "toccata.fugue.com"; | ||
#} | ||
|
||
# Fixed IP addresses can also be specified for hosts. These addresses | ||
# should not also be listed as being available for dynamic assignment. | ||
# Hosts for which fixed IP addresses have been specified can boot using | ||
# BOOTP or DHCP. Hosts for which no fixed address is specified can only | ||
# be booted with DHCP, unless there is an address range on the subnet | ||
# to which a BOOTP client is connected which has the dynamic-bootp flag | ||
# set. | ||
#host fantasia { | ||
# hardware ethernet 08:00:07:26:c0:a5; | ||
# fixed-address fantasia.fugue.com; | ||
#} | ||
|
||
# You can declare a class of clients and then do address allocation | ||
# based on that. The example below shows a case where all clients | ||
# in a certain class get addresses on the 10.17.224/24 subnet, and all | ||
# other clients get addresses on the 10.0.29/24 subnet. | ||
|
||
#class "foo" { | ||
# match if substring (option vendor-class-identifier, 0, 4) = "SUNW"; | ||
#} | ||
|
||
#shared-network 224-29 { | ||
# subnet 10.17.224.0 netmask 255.255.255.0 { | ||
# option routers rtr-224.example.org; | ||
# } | ||
# subnet 10.0.29.0 netmask 255.255.255.0 { | ||
# option routers rtr-29.example.org; | ||
# } | ||
# pool { | ||
# allow members of "foo"; | ||
# range 10.17.224.10 10.17.224.250; | ||
# } | ||
# pool { | ||
# deny members of "foo"; | ||
# range 10.0.29.10 10.0.29.230; | ||
# } | ||
#} | ||
|
||
<% node[:dhcpd][:hosts].each do |name, config| %> | ||
host <%= name %> { | ||
hardware ethernet <%= config[:mac_address] %>; | ||
fixed-address <%= config[:ip_address] %>; | ||
|
||
option host-name "<%= name %>"; | ||
option domain-name "<%= node[:domain] %>"; | ||
option routers "<%= node[:dhcpd][:gateway] %>"; | ||
option subnet-mask "<%= node[:dhcpd][:netmask] %>"; | ||
|
||
<% if config[:pxe_boot] %> | ||
next-server <%= node[:dhcpd][:tftp_server] %>; | ||
filename "pxelinux.0"; # file on TFTP server | ||
<% 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,8 @@ | ||
djbdns Mash.new unless attribute?("djbdns") | ||
|
||
djbdns[:tinydns_ipaddress] = "127.0.0.1" unless djbdns.has_key?(:tinydns_ipaddress) | ||
djbdns[:tinydns_internal_ipaddress] = "127.0.0.1" unless djbdns.has_key?(:tinydns_internal_ipaddress) | ||
djbdns[:axfrdns_ipaddress] = "127.0.0.1" unless djbdns.has_key?(:axfrdns_ipaddress) | ||
djbdns[:public_dnscache_ipaddress] = ipaddress unless djbdns.has_key?(:public_dnscache_ipaddress) | ||
default.djbdns[:tinydns_ipaddress] = "127.0.0.1" | ||
default.djbdns[:tinydns_internal_ipaddress] = "127.0.0.1" | ||
default.djbdns[:axfrdns_ipaddress] = "127.0.0.1" | ||
default.djbdns[:public_dnscache_ipaddress] = node[:ipaddress] | ||
# Default allowed networks is the current network class B | ||
djbdns[:public_dnscache_allowed_networks] = [ipaddress.split(".")[0,2].join(".")] unless djbdns.has_key?(:public_dnscache_allowed_networks) | ||
default.djbdns[:public_dnscache_allowed_networks] = [node[:ipaddress].split(".")[0,2].join(".")] | ||
# Reverse DNS (PTR) networks | ||
djbdns[:ptr_networks] = ['10.10', '172.16'] unless djbdns.has_key?(:ptr_networks) | ||
|
||
# this may not exist on a first run of chef-solo on ec2 | ||
if attribute?("domain") | ||
djbdns[:tinydns_internal_resolved_domain] = domain unless djbdns.has_key?(:tinydns_internal_resolved_domain) | ||
end | ||
default.djbdns[:ptr_networks] = ['10.10', '172.16'] |
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
Oops, something went wrong.