Created
March 2, 2011 02:28
-
-
Save jtimberman/850354 to your computer and use it in GitHub Desktop.
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
# | |
# Cookbook Name:: workstation | |
# Recipe:: default | |
# | |
# Copyright 2010, Joshua Timberman | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
# See the License for the specific language governing permissions and | |
# limitations under the License. | |
# | |
wk = data_bag_item(:apps,:workstation) | |
wk['gems'].each do |g,v| | |
gem_package g do | |
action :install | |
version v if v && v.length > 0 | |
end | |
end | |
if Chef::Platform.find_provider_for_node(node, :package) == Chef::Provider::Package::Homebrew | |
wk['packages'].each do |p,v| | |
package p do | |
action :install | |
version v if v && v.length > 0 | |
end | |
end | |
end | |
case node['platform'] | |
when "mac_os_x" | |
directory "#{ENV['HOME']}/Applications" | |
wk['dmgs'].each do |pkg, data| | |
dmg_package pkg do | |
volumes_dir data['volumes_dir'] if data.has_key?('volumes_dir') | |
dmg_name data['dmg_name'] if data.has_key?('dmg_name') | |
source data['url'] | |
checksum data['checksum'] | |
action :install | |
end | |
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
{ | |
"dmgs": { | |
"Skype": { | |
"url": "http://www.skype.com/go/getskype-macosx.dmg", | |
"checksum": "f13c778cef334f36f10c5df9675838bb751477d867b755a940718e4969a33a48" | |
}, | |
"Google Chrome": { | |
"dmg_name": "googlechrome", | |
"url": "https://dl-ssl.google.com/chrome/mac/stable/GGRM/googlechrome.dmg", | |
"checksum": "7daa2dc5c46d9bfb14f1d7ff4b33884325e5e63e694810adc58f14795165c91a" | |
}, | |
"MacIrssi": { | |
"url": "http://www.sysctl.co.uk/projects/macirssi/downloads/MacIrssi-0.8.6.6.dmg", | |
"checksum": "23c01be8c7b7bdb7268d0d92350ad89949c38bb248634a1385cf9ed0584f74a6" | |
}, | |
"Steam": { | |
"url": "http://cdn.store.steampowered.com/public/client/installer/steam.dmg", | |
"checksum": "e36f5bc1f8b84c70c4862c841d9344e912dac833226b2a04f625cf43a97cba9d" | |
}, | |
"Tunnelblick": { | |
"url": "http://tunnelblick.googlecode.com/files/Tunnelblick_3.1.2.dmg", | |
"checksum": "a3fae60b6833175f32df20c90cd3a3603a" | |
}, | |
"Picasa": { | |
"url": "http://dl.google.com/photos/picasamac38.dmg", | |
"checksum": "5e464f6ac3dce075cda7796c3b360a366ba8e66458458dd2110869bb15534e85" | |
}, | |
"Dropbox": { | |
"url": "http://www.dropbox.com/download?plat=mac", | |
"checksum": "b4ea620ca22b0517b75753283ceb82326aca8bc3c86212fbf725de6446a96a13", | |
"volumes_dir": "Dropbox Installer" | |
}, | |
"Adium": { | |
"url": "http://download.adium.im/Adium_1.4.1.dmg", | |
"checksum": "5c6971d7d4df3a8b7cce703bcb75ea14973eb3bdda1da46fb7a9451b5a27105d", | |
"volumes_dir": "Adium 1.4.1" | |
}, | |
"Chicken of the VNC": { | |
"dmg_name": "cotvnc-20b4", | |
"url": "http://downloads.sourceforge.net/project/cotvnc/cotvnc/Chicken%20of%20the%20VNC%202.0b4/cotvnc-20b4.dmg", | |
"checksum": "804b80372c6ac862f4e3f1230ce846c8daf7897aaa029190521a613e615e5604", | |
"volumes_dir": "Chicken of the VNC" | |
} | |
}, | |
"packages": { | |
"md5sha1sum": "", | |
"openvpn": "", | |
"macvim": "", | |
"emacs": "", | |
"wget": "", | |
"git": "", | |
"tmux": "", | |
"ack": "" | |
}, | |
"id": "workstation", | |
"gems": { | |
"net-sftp": "", | |
"ronn": "", | |
"bluecloth": "", | |
"highline": "", | |
"showoff": "", | |
"prawn": "", | |
"ohai": "0.5.8", | |
"thor": "0.14.4", | |
"net-ssh-multi": "", | |
"rspec": "1.3.0", | |
"git-up": "", | |
"grit": "", | |
"nanoc": "", | |
"adsf": "", | |
"wirble": "", | |
"sdoc": "", | |
"chef": "0.9.14.beta.1", | |
"json": "1.4.6", | |
"awesome_print": "", | |
"gem-man": "", | |
"qwandry": "", | |
"ghost": "", | |
"jeweler": "", | |
"gist": "", | |
"org-ruby": "", | |
"fog": "", | |
"cucumber": "", | |
"vagrant": "", | |
"yajl-ruby": "", | |
"ubuntu_ami": "", | |
"capistrano": "", | |
"cheat": "", | |
"kramdown": "" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment