1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

F #4163: Added path to rubygems (packages)

(cherry picked from commit 8ff86586727331397159ed7b48c1a3e481c58ca0)
This commit is contained in:
Ruben S. Montero 2020-02-10 11:53:55 +01:00
parent 944f12446d
commit 9a4d34de90
No known key found for this signature in database
GPG Key ID: A0CEA6FA880A1D87

View File

@ -16,6 +16,22 @@
# limitations under the License. #
# -------------------------------------------------------------------------- #
ONE_LOCATION = ENV['ONE_LOCATION']
if !ONE_LOCATION
RUBY_LIB_LOCATION = '/usr/lib/one/ruby'
GEMS_LOCATION = '/usr/share/one/gems'
else
RUBY_LIB_LOCATION = ONE_LOCATION + '/lib/ruby'
GEMS_LOCATION = ONE_LOCATION + '/share/gems'
end
if File.directory?(GEMS_LOCATION)
Gem.use_paths(GEMS_LOCATION)
end
$LOAD_PATH << RUBY_LIB_LOCATION
require 'net/http'
require 'uri'
require 'json'