Class: Google::Apis::CloudkmsV1::AutokeyConfig

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

Overview

Cloud KMS Autokey configuration for a folder.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ AutokeyConfig

Returns a new instance of AutokeyConfig.



349
350
351
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 349

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

Instance Attribute Details

#key_projectString

Optional. Name of the key project, e.g. projects/PROJECT_IDor `projects/` PROJECT_NUMBER, where Cloud KMS Autokey will provision a new CryptoKey when a KeyHandle is created. On UpdateAutokeyConfig, the caller will require cloudkms.cryptoKeys.setIamPolicy permission on this key project. Once configured, for Cloud KMS Autokey to function properly, this key project must have the Cloud KMS API activated and the Cloud KMS Service Agent for this key project must be granted the cloudkms.admin role (or pertinent permissions). A request with an empty key project field will clear the configuration. Corresponds to the JSON property keyProject

Returns:

  • (String)


336
337
338
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 336

def key_project
  @key_project
end

#nameString

Identifier. Name of the AutokeyConfig resource, e.g. folders/FOLDER_NUMBER/ autokeyConfig. Corresponds to the JSON property name

Returns:

  • (String)


342
343
344
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 342

def name
  @name
end

#stateString

Output only. The state for the AutokeyConfig. Corresponds to the JSON property state

Returns:

  • (String)


347
348
349
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 347

def state
  @state
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



354
355
356
357
358
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 354

def update!(**args)
  @key_project = args[:key_project] if args.key?(:key_project)
  @name = args[:name] if args.key?(:name)
  @state = args[:state] if args.key?(:state)
end