clc-fork-chef-metal 0.12.1.alpha.1 → 0.12.1.alpha.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4ab0dfcf01d64e7867adf5fcb1a471d3b7754af4
4
- data.tar.gz: 8afd4982fce7d3dce5c2ab3749b5731ba68e0995
3
+ metadata.gz: 7bcd93ebfac968b282e559c485c35889c57d6c6c
4
+ data.tar.gz: 54ab43bc41b1e6ee9bb63ea19876910ff4f02ff4
5
5
  SHA512:
6
- metadata.gz: 80c3ec5240a3b63ab65f7b2d3f2d8d16754e082ace4206566ead55419cfb22c659bd2ad2513aa5a30e132a57c63043809f76490adf52d6f363ebed7788d1173c
7
- data.tar.gz: df2649567b1d3debeebd4b77bf4e223c5dc5f682588c9b1b39b337e8fb0e5128a41e20d1f0cf6dbd2f4da2e72e520022af72c9631112d169e8f912060416928e
6
+ metadata.gz: da636a7cc0bb2af11cc780f44a8f4609e0818e11eef052ece1811af43b60b3214004f1507eab79b74a7ec039a60cef64de3a4e2a037b0cd3b0aad5f5f6b0ac1f
7
+ data.tar.gz: df764e82aa296219ef82c485a6c17613a360dedc81ba6bd8b9a64896c1cb6297dd25e0e9535ba9ecfa8a92a335a721d2b00dd1e08504ba7f77a106f97f1683c0
@@ -79,6 +79,18 @@ $file.Close
79
79
  false
80
80
  end
81
81
 
82
+ def make_url_available_to_remote(local_url)
83
+ uri = URI(local_url)
84
+ host = Socket.getaddrinfo(uri.host, uri.scheme, nil, :STREAM)[0][3]
85
+ if host == '127.0.0.1' || host == '::1'
86
+ unless session.forward.active_remotes.any? { |port, bind| port == uri.port && bind == uri.host }
87
+ Chef::Log.debug("Forwarding local server #{uri.host}:#{uri.port} to port #{uri.port} on #{username}@#{self.host}")
88
+ session.forward.remote(uri.port, uri.host, uri.port)
89
+ end
90
+ end
91
+ local_url
92
+ end
93
+
82
94
  protected
83
95
 
84
96
  def session
@@ -1,3 +1,3 @@
1
1
  module ChefMetal
2
- VERSION = '0.12.1.alpha.1'
2
+ VERSION = '0.12.1.alpha.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: clc-fork-chef-metal
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.1.alpha.1
4
+ version: 0.12.1.alpha.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Keiser