diff --git a/src/market_mad/remotes/turnkeylinux/monitor b/src/market_mad/remotes/turnkeylinux/monitor index d5235414ed..77015567e9 100755 --- a/src/market_mad/remotes/turnkeylinux/monitor +++ b/src/market_mad/remotes/turnkeylinux/monitor @@ -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'