Class: SDM::ManagedSecret
- Inherits:
-
Object
- Object
- SDM::ManagedSecret
- Defined in:
- lib/models/porcelain.rb
Overview
ManagedSecret contains details about managed secret
Instance Attribute Summary collapse
-
#config ⇒ Object
public part of the secret value.
-
#expires_at ⇒ Object
Timestamp of when secret is going to be rotated.
-
#id ⇒ Object
Unique identifier of the Managed Secret.
-
#last_rotated_at ⇒ Object
Timestamp of when secret was last rotated.
-
#lock_required ⇒ Object
Whether the secret requires a lock to access.
-
#name ⇒ Object
Unique human-readable name of the Managed Secret.
-
#policy ⇒ Object
Password and rotation policy for the secret.
-
#secret_engine_id ⇒ Object
An ID of a Secret Engine linked with the Managed Secret.
-
#secret_store_path ⇒ Object
Path in a secret store.
-
#tags ⇒ Object
Tags is a map of key, value pairs.
-
#value ⇒ Object
Sensitive value of the secret.
Instance Method Summary collapse
-
#initialize(config: nil, expires_at: nil, id: nil, last_rotated_at: nil, lock_required: nil, name: nil, policy: nil, secret_engine_id: nil, secret_store_path: nil, tags: nil, value: nil) ⇒ ManagedSecret
constructor
A new instance of ManagedSecret.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(config: nil, expires_at: nil, id: nil, last_rotated_at: nil, lock_required: nil, name: nil, policy: nil, secret_engine_id: nil, secret_store_path: nil, tags: nil, value: nil) ⇒ ManagedSecret
Returns a new instance of ManagedSecret.
10962 10963 10964 10965 10966 10967 10968 10969 10970 10971 10972 10973 10974 10975 10976 10977 10978 10979 10980 10981 10982 10983 10984 10985 10986 |
# File 'lib/models/porcelain.rb', line 10962 def initialize( config: nil, expires_at: nil, id: nil, last_rotated_at: nil, lock_required: nil, name: nil, policy: nil, secret_engine_id: nil, secret_store_path: nil, tags: nil, value: nil ) @config = config == nil ? "" : config @expires_at = expires_at == nil ? nil : expires_at @id = id == nil ? "" : id @last_rotated_at = last_rotated_at == nil ? nil : last_rotated_at @lock_required = lock_required == nil ? false : lock_required @name = name == nil ? "" : name @policy = policy == nil ? nil : policy @secret_engine_id = secret_engine_id == nil ? "" : secret_engine_id @secret_store_path = secret_store_path == nil ? "" : secret_store_path @tags = == nil ? SDM::() : @value = value == nil ? "" : value end |
Instance Attribute Details
#config ⇒ Object
public part of the secret value
10940 10941 10942 |
# File 'lib/models/porcelain.rb', line 10940 def config @config end |
#expires_at ⇒ Object
Timestamp of when secret is going to be rotated
10942 10943 10944 |
# File 'lib/models/porcelain.rb', line 10942 def expires_at @expires_at end |
#id ⇒ Object
Unique identifier of the Managed Secret.
10944 10945 10946 |
# File 'lib/models/porcelain.rb', line 10944 def id @id end |
#last_rotated_at ⇒ Object
Timestamp of when secret was last rotated
10946 10947 10948 |
# File 'lib/models/porcelain.rb', line 10946 def last_rotated_at @last_rotated_at end |
#lock_required ⇒ Object
Whether the secret requires a lock to access
10948 10949 10950 |
# File 'lib/models/porcelain.rb', line 10948 def lock_required @lock_required end |
#name ⇒ Object
Unique human-readable name of the Managed Secret.
10950 10951 10952 |
# File 'lib/models/porcelain.rb', line 10950 def name @name end |
#policy ⇒ Object
Password and rotation policy for the secret
10952 10953 10954 |
# File 'lib/models/porcelain.rb', line 10952 def policy @policy end |
#secret_engine_id ⇒ Object
An ID of a Secret Engine linked with the Managed Secret.
10954 10955 10956 |
# File 'lib/models/porcelain.rb', line 10954 def secret_engine_id @secret_engine_id end |
#secret_store_path ⇒ Object
Path in a secret store.
10956 10957 10958 |
# File 'lib/models/porcelain.rb', line 10956 def secret_store_path @secret_store_path end |
#tags ⇒ Object
Tags is a map of key, value pairs.
10958 10959 10960 |
# File 'lib/models/porcelain.rb', line 10958 def @tags end |
#value ⇒ Object
Sensitive value of the secret.
10960 10961 10962 |
# File 'lib/models/porcelain.rb', line 10960 def value @value end |
Instance Method Details
#to_json(options = {}) ⇒ Object
10988 10989 10990 10991 10992 10993 10994 |
# File 'lib/models/porcelain.rb', line 10988 def to_json( = {}) hash = {} self.instance_variables.each do |var| hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var end hash.to_json end |