B #-: Fix load_paths for lxc poll.rb (#3845)

This commit is contained in:
Jan Orel authored and GitHub committed 2025-10-02 10:49:14 +02:00
1 parent 958b15772b
commit 133b3ade69
1 file changed
+18
@@ -1,5 +1,23 @@
#!/usr/bin/ruby
ONE_LOCATION = ENV['ONE_LOCATION'] unless defined?(ONE_LOCATION)
if !ONE_LOCATION
LIB_LOCATION ||= '/usr/lib/one'
RUBY_LIB_LOCATION ||= '/usr/lib/one/ruby'
GEMS_LOCATION ||= '/usr/share/one/gems'
else
LIB_LOCATION ||= ONE_LOCATION + '/lib'
RUBY_LIB_LOCATION ||= ONE_LOCATION + '/lib/ruby'
GEMS_LOCATION ||= ONE_LOCATION + '/share/gems'
end
# %%RUBYGEMS_SETUP_BEGIN%%
require 'load_opennebula_paths'
# %%RUBYGEMS_SETUP_END%%
$LOAD_PATH << RUBY_LIB_LOCATION
require_relative '../../../lib/lxc'
puts DomainList.info