Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 68 lines (56 sloc) 1.38 KB
#!/usr/bin/ruby
ONE_LOCATION=ENV["ONE_LOCATION"]
if !ONE_LOCATION
RUBY_LIB_LOCATION="/usr/lib/one/ruby"
VAR_LOCATION = "/var/lib/one"
LIB_LOCATION = "/usr/lib/one"
ETC_LOCATION = "/etc/one"
else
RUBY_LIB_LOCATION=ONE_LOCATION+"/lib/ruby"
VAR_LOCATION = ONE_LOCATION+"/var"
LIB_LOCATION = ONE_LOCATION+"/lib"
ETC_LOCATION = ONE_LOCATION + "/etc"
end
$: << RUBY_LIB_LOCATION
$: << RUBY_LIB_LOCATION+"/cloud" # For the Repository Manager
$: << RUBY_LIB_LOCATION+"/cli" # For the Repository Manager
$: << LIB_LOCATION+'/oneflow/lib'
################################################
# Required libraries
################################################
require 'base64'
require 'csv'
require 'date'
require 'digest/md5'
require 'erb'
require 'fileutils'
require 'json'
require 'nokogiri'
require 'openssl'
require 'ox'
require 'set'
require 'socket'
require 'sqlite3'
require 'tempfile'
require 'time'
require 'uri'
require 'yaml'
require 'pp'
require 'opennebula'
require 'vcenter_driver'
include OpenNebula
@client = Client.new
module OpenNebula
class XMLElement
def self.from_xml(s)
m = s.match(/^<(\w+)>/)
root_element = m[1]
elem = XMLElement.new
elem.initialize_xml(s, root_element)
return elem
end
end
end
version = ">= 0"
gem 'pry', version
load Gem.bin_path('pry', 'pry', version)