Class: Google::Apis::RunV2::GoogleCloudRunV2SecretKeySelector

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/run_v2/classes.rb,
lib/google/apis/run_v2/representations.rb,
lib/google/apis/run_v2/representations.rb

Overview

SecretEnvVarSource represents a source for the value of an EnvVar.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRunV2SecretKeySelector

Returns a new instance of GoogleCloudRunV2SecretKeySelector.



1503
1504
1505
# File 'lib/google/apis/run_v2/classes.rb', line 1503

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#secretString

Required. The name of the secret in Cloud Secret Manager. Format: secret_name if the secret is in the same project. projects/project/secrets/secret_name if the secret is in a different project. Corresponds to the JSON property secret

Returns:

  • (String)


1495
1496
1497
# File 'lib/google/apis/run_v2/classes.rb', line 1495

def secret
  @secret
end

#versionString

The Cloud Secret Manager secret version. Can be 'latest' for the latest version, an integer for a specific version, or a version alias. Corresponds to the JSON property version

Returns:

  • (String)


1501
1502
1503
# File 'lib/google/apis/run_v2/classes.rb', line 1501

def version
  @version
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1508
1509
1510
1511
# File 'lib/google/apis/run_v2/classes.rb', line 1508

def update!(**args)
  @secret = args[:secret] if args.key?(:secret)
  @version = args[:version] if args.key?(:version)
end