From f6c6fe0e03625c4d906f3b98b5b6933f5d781533 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Tue, 25 Jun 2013 20:43:45 +0100 Subject: [PATCH] Add support for the hwraid apt repository --- cookbooks/apt/definitions/apt_source.rb | 8 +++++--- cookbooks/apt/recipes/default.rb | 4 ++++ 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/cookbooks/apt/definitions/apt_source.rb b/cookbooks/apt/definitions/apt_source.rb index c109707a9..f98b2b22c 100644 --- a/cookbooks/apt/definitions/apt_source.rb +++ b/cookbooks/apt/definitions/apt_source.rb @@ -21,9 +21,11 @@ define :apt_source do if node.apt.sources.include?(params[:name]) source_action = :create - execute "apt-key-#{params[:key]}" do - command "/usr/bin/apt-key adv --keyserver hkp://keys.gnupg.net --recv-keys #{params[:key]}" - not_if "/usr/bin/apt-key list | /bin/fgrep -q #{params[:key]}" + if params[:key] + execute "apt-key-#{params[:key]}" do + command "/usr/bin/apt-key adv --keyserver hkp://keys.gnupg.net --recv-keys #{params[:key]}" + not_if "/usr/bin/apt-key list | /bin/fgrep -q #{params[:key]}" + end end else source_action = :delete diff --git a/cookbooks/apt/recipes/default.rb b/cookbooks/apt/recipes/default.rb index 4b5fdf7a7..5756e0396 100644 --- a/cookbooks/apt/recipes/default.rb +++ b/cookbooks/apt/recipes/default.rb @@ -100,6 +100,10 @@ apt_source "management-component-pack" do key "2689B887" end +apt_source "hwraid" do + url "http://hwraid.le-vert.net/ubuntu" +end + apt_source "mapnik-v210" do url "http://ppa.launchpad.net/mapnik/v2.1.0/ubuntu" key "5D50B6BA" -- 2.39.5