Sha256: 100543af6c760cf664754a891e2da2a954be509dc9e420d608c0adfe13f0514f
Contents?: true
Size: 750 Bytes
Versions: 12
Compression:
Stored size: 750 Bytes
Contents
require "pathname" require "vagrant-g5k/plugin" require 'thread' module VagrantPlugins module G5K class << self attr_accessor :g5k_lock attr_accessor :subnet_lock attr_accessor :pool end @g5k_lock = Mutex.new @subnet_lock = Mutex.new @pool = {} lib_path = Pathname.new(File.expand_path("../vagrant-g5k", __FILE__)) autoload :Action, lib_path.join("action") autoload :Errors, lib_path.join("errors") # This returns the path to the source of this plugin. # # @return [Pathname] def self.source_root @source_root ||= Pathname.new(File.expand_path("../../", __FILE__)) end def lockable(opts) opts[:lock].synchronize { yield } end end end
Version data entries
12 entries across 12 versions & 1 rubygems