Port -> app_port
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
class Kamal::Commands::Proxy < Kamal::Commands::Base
|
||||
delegate :argumentize, :optionize, to: Kamal::Utils
|
||||
delegate :container_name, :port, to: :proxy_config
|
||||
delegate :container_name, :app_port, to: :proxy_config
|
||||
|
||||
attr_reader :proxy_config
|
||||
|
||||
@@ -35,11 +35,11 @@ class Kamal::Commands::Proxy < Kamal::Commands::Base
|
||||
end
|
||||
|
||||
def deploy(service, target:)
|
||||
docker :exec, container_name, "kamal-proxy", :deploy, service, *optionize({ target: "#{target}:#{port}" }), *proxy_config.deploy_command_args
|
||||
docker :exec, container_name, "kamal-proxy", :deploy, service, *optionize({ target: "#{target}:#{app_port}" }), *proxy_config.deploy_command_args
|
||||
end
|
||||
|
||||
def remove(service, target:)
|
||||
docker :exec, container_name, "kamal-proxy", :remove, service, *optionize({ target: "#{target}:#{port}" })
|
||||
docker :exec, container_name, "kamal-proxy", :remove, service, *optionize({ target: "#{target}:#{app_port}" })
|
||||
end
|
||||
|
||||
def info
|
||||
|
||||
@@ -56,11 +56,11 @@ proxy:
|
||||
# requests for other apps that do have a host set.
|
||||
host: foo.example.com
|
||||
|
||||
# Port
|
||||
# App port
|
||||
#
|
||||
# The port the application is exposed on
|
||||
# The port the application container is exposed on
|
||||
# Defaults to 80
|
||||
port: 3000
|
||||
app_port: 3000
|
||||
|
||||
# SSL
|
||||
#
|
||||
|
||||
@@ -25,8 +25,8 @@ class Kamal::Configuration::Proxy
|
||||
end
|
||||
end
|
||||
|
||||
def port
|
||||
proxy_config.fetch("port", 80)
|
||||
def app_port
|
||||
proxy_config.fetch("app_port", 80)
|
||||
end
|
||||
|
||||
def image
|
||||
|
||||
Reference in New Issue
Block a user