dash 4.3.0 → 4.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b4da415bef9c24e1cb953025f5b613e252adc7a5e701022d45ef3a5ead57c5e7
4
- data.tar.gz: 44e8b217a33121af0ce8817610a12c820bbc44b2cf91377fbd46f3a1ae1d3258
3
+ metadata.gz: dc1b627f67a26c559766675b05520f13b49bc632ae72b00abfee08d806492e3a
4
+ data.tar.gz: '0868bc43a71299d4f4567d0b322ced4b2454cc640502b9cd8e7a01e923a2a75a'
5
5
  SHA512:
6
- metadata.gz: ee1355429c12f34ee0bcd27da1849e196db86aa8761b5e03c0e485870a46c8b583fe1b6aba44d134d169ebbc625be846c676771dd84f50b38bb887419ddf7354
7
- data.tar.gz: d48f6487c407811f6edba7da6c140773eb37d72e18a44811bf4acd285b1f25bb095a8b63d9c9e3d201c641230e202f76da68a1fb5d6bb76f1949547736debb95
6
+ metadata.gz: 87f99fe550d1256059f29f0fdfba3540b1f24d3d94d2761003b517b48cb8659b5196206e959408a4f6cd5514b1a74de3b4f7888e1d545b9c1035218123336469
7
+ data.tar.gz: 1b3fd06c1844f66b87af0dec4cf1661b6422d8b3da8e9f952d749d8a3dcd289675860e4cb326e4a26c04687a7a64daaf42c8e17d712f7a9dbd667ed40692baf6
@@ -237,9 +237,12 @@ class Dash::Cli::Build < Dash::Cli::Base
237
237
  def connect_to_remote_host(remote_host)
238
238
  remote_uri = URI.parse(remote_host)
239
239
  if remote_uri.scheme == "ssh"
240
+ # `ssh.proxy` is how dash reaches the hosts it deploys to, not the builder. Like the
241
+ # docker context buildx uses for it, the builder connection takes its jump host (if
242
+ # any) from ~/.ssh/config, so `proxy: nil` stops the global one from being merged in.
240
243
  host = SSHKit::Host.new(
241
244
  hostname: remote_uri.host,
242
- ssh_options: { user: remote_uri.user, port: remote_uri.port }.compact
245
+ ssh_options: { user: remote_uri.user, port: remote_uri.port }.compact.merge(proxy: nil)
243
246
  )
244
247
  on(host, options) do
245
248
  execute "true"
@@ -21,6 +21,12 @@ builder:
21
21
  #
22
22
  # The connection string for a remote builder. If supplied, dash will use this
23
23
  # for builds that do not match the local architecture of the deployment host.
24
+ #
25
+ # The connection to the builder does not go through `ssh.proxy` or
26
+ # `ssh.proxy_command`, which are for the hosts dash deploys to. A builder that
27
+ # must itself be reached through a jump host says so in `~/.ssh/config`
28
+ # (`ProxyJump`). The docker SSH context that buildx uses for the builder reads
29
+ # that file too.
24
30
  remote: ssh://docker@docker-builder
25
31
 
26
32
  # Local
@@ -29,11 +29,15 @@ ssh:
29
29
 
30
30
  # Proxy host
31
31
  #
32
+ # Used for the hosts dash deploys to, not for a remote builder (`builder.remote`).
33
+ #
32
34
  # Specified in the form <host> or <user>@<host>:
33
35
  proxy: root@proxy-host
34
36
 
35
37
  # Proxy command
36
38
  #
39
+ # Like `proxy`, not used for a remote builder.
40
+ #
37
41
  # A custom proxy command, required for older versions of SSH:
38
42
  proxy_command: "ssh -W %h:%p user@proxy"
39
43
 
@@ -183,13 +183,18 @@ class SSHKit::Backend::Netssh
183
183
 
184
184
  module LimitConcurrentStartsInstance
185
185
  private
186
+ # A host can opt out of a global option by setting it to nil (the remote builder sets
187
+ # `proxy: nil` so it doesn't inherit `ssh.proxy`). The nil stays on the host so every
188
+ # later merge still overrides the global, but it never reaches Net::SSH.start: net-ssh
189
+ # merges explicit options over ~/.ssh/config, so a nil would also discard what the
190
+ # operator configured for that host there (and net-ssh warns about nil options).
186
191
  def with_ssh(&block)
187
192
  host.ssh_options = self.class.config.ssh_options.merge(host.ssh_options || {})
188
193
  self.class.pool.with(
189
194
  method(:connect_ssh),
190
195
  String(host.hostname),
191
196
  host.username,
192
- host.netssh_options,
197
+ host.netssh_options.compact,
193
198
  &block
194
199
  )
195
200
  end
data/lib/dash/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Dash
2
- VERSION = "4.3.0"
2
+ VERSION = "4.3.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dash
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.0
4
+ version: 4.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mikael Henriksson