Merge pull request #620 from mlitwiniuk/allow_custom_ports_for_ssh
Allow custom user and port for builder host
This commit is contained in:
@@ -127,8 +127,11 @@ class Kamal::Cli::Build < Kamal::Cli::Base
|
||||
def connect_to_remote_host(remote_host)
|
||||
remote_uri = URI.parse(remote_host)
|
||||
if remote_uri.scheme == "ssh"
|
||||
options = { user: remote_uri.user, port: remote_uri.port }.compact
|
||||
on(remote_uri.host, options) do
|
||||
host = SSHKit::Host.new(
|
||||
hostname: remote_uri.host,
|
||||
ssh_options: { user: remote_uri.user, port: remote_uri.port }.compact
|
||||
)
|
||||
on(host, options) do
|
||||
execute "true"
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user