Skip to content

Commit

Permalink
Delegate instead of define new method
Browse files Browse the repository at this point in the history
  • Loading branch information
igor-alexandrov committed Oct 9, 2024
1 parent 9d08d00 commit e23103a
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions lib/kamal/configuration.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ class Kamal::Configuration
attr_reader :destination, :raw_config, :secrets
attr_reader :accessories, :aliases, :boot, :builder, :env, :logging, :proxy, :servers, :ssh, :sshkit, :registry

delegate :container_name, to: :proxy, prefix: true

include Validation

PROXY_MINIMUM_VERSION = "v0.8.0"
Expand Down Expand Up @@ -265,10 +267,6 @@ def proxy_image
"basecamp/kamal-proxy:#{PROXY_MINIMUM_VERSION}"
end

def proxy_container_name
proxy.container_name
end

def proxy_directory
File.join run_directory, "proxy"
end
Expand Down

0 comments on commit e23103a

Please sign in to comment.