Merge pull request #988 from igor-alexandrov/kamal-proxy-remove-no-target
Fixed kamal-proxy remove command
This commit is contained in:
@@ -68,7 +68,7 @@ class Kamal::Cli::App < Kamal::Cli::Base
|
||||
version = capture_with_info(*app.current_running_version, raise_on_non_zero_exit: false).strip
|
||||
endpoint = capture_with_info(*app.container_id_for_version(version)).strip
|
||||
if endpoint.present?
|
||||
execute *app.remove(target: endpoint), raise_on_non_zero_exit: false
|
||||
execute *app.remove, raise_on_non_zero_exit: false
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -5,8 +5,8 @@ module Kamal::Commands::App::Proxy
|
||||
proxy_exec :deploy, role.container_prefix, *role.proxy.deploy_command_args(target: target)
|
||||
end
|
||||
|
||||
def remove(target:)
|
||||
proxy_exec :remove, role.container_prefix, *role.proxy.remove_command_args(target: target)
|
||||
def remove
|
||||
proxy_exec :remove, role.container_prefix
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
@@ -51,10 +51,6 @@ class Kamal::Configuration::Proxy
|
||||
optionize ({ target: "#{target}:#{app_port}" }).merge(deploy_options)
|
||||
end
|
||||
|
||||
def remove_command_args(target:)
|
||||
optionize({ target: "#{target}:#{app_port}" })
|
||||
end
|
||||
|
||||
def merge(other)
|
||||
self.class.new config: config, proxy_config: proxy_config.deep_merge(other.proxy_config)
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user