Module: KubesGoogle

Extended by:
KubesGoogle
Included in:
KubesGoogle
Defined in:
lib/kubes_google.rb,
lib/kubes_google/gke.rb,
lib/kubes_google/hooks.rb,
lib/kubes_google/config.rb,
lib/kubes_google/helpers.rb,
lib/kubes_google/logging.rb,
lib/kubes_google/secrets.rb,
lib/kubes_google/version.rb,
lib/kubes_google/services.rb,
lib/kubes_google/autoloader.rb,
lib/kubes_google/service_account.rb

Defined Under Namespace

Modules: Helpers, Logging, Services, Util Classes: Autoloader, Config, Error, Gke, Hooks, Secrets, ServiceAccount, VpnSslError

Constant Summary collapse

VERSION =
"0.3.11"
@@logger =
nil

Instance Method Summary collapse

Instance Method Details

#cloudbuild?Boolean

Returns:

  • (Boolean)


39
40
41
# File 'lib/kubes_google.rb', line 39

def cloudbuild?
  !!ENV['BUILDER_OUTPUT'] # cloudbuild env vars: https://gist.github.com/tongueroo/7ae26abd60d30da3972e86b4e7ca315e
end

#configObject



35
36
37
# File 'lib/kubes_google.rb', line 35

def config
  Config.instance.config
end

#configure(&block) ⇒ Object

Friendlier method configure.

.kubes/config/env/dev.rb
.kubes/config/plugins/google.rb # also works

Example:

KubesGoogle.configure do |config|
  config.hooks.gke_whitelist = true
end


31
32
33
# File 'lib/kubes_google.rb', line 31

def configure(&block)
  Config.instance.configure(&block)
end

#loggerObject



12
13
14
# File 'lib/kubes_google.rb', line 12

def logger
  @@logger ||= Kubes.logger
end

#logger=(v) ⇒ Object



16
17
18
# File 'lib/kubes_google.rb', line 16

def logger=(v)
  @@logger = v
end