Skip to content

Commit

Permalink
Pass options from K8s::Client.in_cluster_config to Transport (#88)
Browse files Browse the repository at this point in the history
* Make K8s::Client.in_cluster_config pass options to Transport.in_cluster_config

* Pass them to the right place

* Update client.rb

* Update client.rb
  • Loading branch information
kke authored Jan 7, 2019
1 parent 99bc979 commit e94fd9b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/k8s/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,11 @@ def self.config(config, namespace: nil, **options)
# @see K8s::Transport#in_cluster_config
#
# @param namespace [String] default namespace for all operations
# @param options [Hash] options passed to transport, @see Transport#in_cluster_config
# @return [K8s::Client]
# @raise [K8s::Error::Config,Errno::ENOENT,Errno::EACCES]
def self.in_cluster_config(namespace: nil)
new(Transport.in_cluster_config, namespace: namespace)
def self.in_cluster_config(namespace: nil, **options)
new(Transport.in_cluster_config(**options), namespace: namespace)
end

# Attempts to create a K8s::Client instance automatically using environment variables, existing configuration
Expand Down

0 comments on commit e94fd9b

Please sign in to comment.