Permalink
Browse files

Merge pull request #17 from winhamwr/issue_15

Issue 15: Compatibility with new version of apt cookbook
  • Loading branch information...
2 parents 071d97a + 229e29f commit 317ab1983718559395ac639248b34ab1e4ae5778 @fnichol committed Dec 5, 2011
Showing with 6 additions and 15 deletions.
  1. +6 −15 recipes/default.rb
View
@@ -105,23 +105,15 @@
end
when "ubuntu"
- package_provider = Chef::Provider::Package::Apt
- package "curl"
- key_url = "http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key"
-
include_recipe "apt"
include_recipe "java"
- cookbook_file "/etc/apt/sources.list.d/jenkins.list" do
- owner "root"
- group "root"
- mode "0644"
- end
-
- execute "add-jenkins-key" do
- command "curl #{key_url} | apt-key add -"
- action :nothing
- notifies :run, "execute[apt-get update]", :immediately
+ apt_repository "jenkins" do
+ uri "http://pkg.jenkins-ci.org/debian"
+ distribution "binary/"
+ components [""]
+ key "http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key"
+ action :add
end
end
@@ -194,7 +186,6 @@
command "echo w00t"
notifies :stop, "service[jenkins]", :immediately
notifies :create, "ruby_block[netstat]", :immediately #wait a moment for the port to be released
- notifies :run, "execute[add-jenkins-key]", :immediately
notifies :install, "package[jenkins]", :immediately
unless install_starts_service
notifies :start, "service[jenkins]", :immediately

0 comments on commit 317ab19

Please sign in to comment.