Skip to content

Instantly share code, notes, and snippets.

Created November 23, 2009 16:25
Show Gist options
  • Save anonymous/241151 to your computer and use it in GitHub Desktop.
Save anonymous/241151 to your computer and use it in GitHub Desktop.
current_apt_keys = Dir[
File.expand_path(File.join(File.dirname(__FILE__), "..", "files", "default", "apt-keys", "*"))
]
ruby_block "cleanup apt-keys" do
block do
Dir[
File.expand_path(File.join(Chef::Config[:file_cache_path], "cache", "apt_keys", "*"))
].each do |rf|
unless current_apt_keys.include?(rf)
File.delete(rf)
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment