Skip to content

Instantly share code, notes, and snippets.

@lusis
Created April 24, 2013 13:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save lusis/5452331 to your computer and use it in GitHub Desktop.
Save lusis/5452331 to your computer and use it in GitHub Desktop.
if ENV['ES_CACHE']
puts "Shared cache enabled"
if ENV['ES_CACHE_TYPE'] == 'yum'
FileUtils.mkdir_p(File.join("cache","yum")) unless Dir.exists?(File.join("cache","yum"))
config.vm.share_folder("yum", "/var/cache/yum", "cache/yum")
else
FileUtils.mkdir_p(File.join("cache","apt","partial")) unless Dir.exists?(File.join("cache","apt", "partial"))
config.vm.share_folder("apt", "/var/cache/apt/archives", "cache/apt")
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment