Skip to content

Commit

Permalink
Revert "F #5917: Support for proxy in datastore drivers (#5977)"
Browse files Browse the repository at this point in the history
This reverts commit 2e953be.
  • Loading branch information
tinova committed Sep 26, 2022
1 parent 2e953be commit 2024f62
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 9 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ share/esx-fw-vnc/*.rpm
share/esx-fw-vnc/.vagrant*

*.vscode
*.code-workspace

share/context/*
!share/context/download_context.sh
Expand Down
9 changes: 1 addition & 8 deletions src/market_mad/one_market.rb
Original file line number Diff line number Diff line change
Expand Up @@ -317,13 +317,12 @@ def failure(asym, id, message)
[ '--threads', '-t', GetoptLong::OPTIONAL_ARGUMENT ],
[ '--market-types', '-m', GetoptLong::OPTIONAL_ARGUMENT ],
[ '--timeout', '-w', GetoptLong::OPTIONAL_ARGUMENT ],
[ '--proxy' '-p' , GetoptLong::OPTIONAL_ARGUMENT ]
[ '--proxy' , GetoptLong::OPTIONAL_ARGUMENT ]
)

mp_type = nil
threads = 15
timeout = nil
proxy = nil

begin
opts.each do |opt, arg|
Expand All @@ -334,18 +333,12 @@ def failure(asym, id, message)
mp_type = arg.split(',').map {|a| a.strip }
when '--timeout'
timeout = arg.to_i
when '--proxy'
timeout = arg.to_i
end
end
rescue Exception => e
exit(-1)
end

#Export proxy ip:port as env var for curl

ENV['http_proxy'] = File.read('/etc/one/oned.conf')[/(?<=--proxy\s)\S+/]

mp_driver = MarketPlaceDriver.new(mp_type,
:concurrency => threads,
:timeout => timeout)
Expand Down

0 comments on commit 2024f62

Please sign in to comment.