This is for boot time configuration for the kamal proxy. Config in here doesn't not belong in Kamal::Configuration::Proxy which is for deploy time configuration for the app itself. Kamal apps don't contain boot time config, because multiple apps can share a proxy and the config could conflict.
17 lines
395 B
Ruby
17 lines
395 B
Ruby
module Kamal::Commands::Accessory::Proxy
|
|
delegate :container_name, to: :"config.proxy_boot", prefix: :proxy
|
|
|
|
def deploy(target:)
|
|
proxy_exec :deploy, service_name, *proxy.deploy_command_args(target: target)
|
|
end
|
|
|
|
def remove
|
|
proxy_exec :remove, service_name
|
|
end
|
|
|
|
private
|
|
def proxy_exec(*command)
|
|
docker :exec, proxy_container_name, "kamal-proxy", *command
|
|
end
|
|
end
|