@Generated(value="jsii-pacmak/1.34.0 (build 9b72778)", date="2021-09-24T22:49:58.428Z") @Stability(value=Stable) public class Secret extends Resource implements ISecret
Storing confidential information in a Secret is safer and more flexible than putting it verbatim in a Pod definition or in a container image.
https://kubernetes.io/docs/concepts/configuration/secret| Modifier and Type | Class and Description |
|---|---|
static class |
Secret.Builder
A fluent builder for
Secret. |
software.amazon.jsii.JsiiObject.InitializationModeISecret.Jsii$Default, ISecret.Jsii$Proxy| Modifier | Constructor and Description |
|---|---|
|
Secret(software.constructs.Construct scope,
String id) |
|
Secret(software.constructs.Construct scope,
String id,
SecretProps props) |
protected |
Secret(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Secret(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
void |
addStringData(String key,
String value)
Adds a string data field to the secert.
|
static ISecret |
fromSecretName(String name)
Imports a secret from the cluster as a reference.
|
protected org.cdk8s.ApiObject |
getApiObject()
The underlying cdk8s API object.
|
String |
getStringData(String key)
Gets a string data by key or undefined.
|
getMetadata, getNameonPrepare, onSynthesize, onValidate, toStringjsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected Secret(software.amazon.jsii.JsiiObjectRef objRef)
protected Secret(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public Secret(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@Nullable
SecretProps props)
scope - This parameter is required.id - This parameter is required.props - @Stability(value=Stable)
public Secret(@NotNull
software.constructs.Construct scope,
@NotNull
String id)
scope - This parameter is required.id - This parameter is required.@Stability(value=Stable) @NotNull public static ISecret fromSecretName(@NotNull String name)
name - The name of the secret to reference. This parameter is required.@Stability(value=Stable)
public void addStringData(@NotNull
String key,
@NotNull
String value)
key - Key. This parameter is required.value - Value. This parameter is required.@Stability(value=Stable) @Nullable public String getStringData(@NotNull String key)
key - Key. This parameter is required.@Stability(value=Stable) @NotNull protected org.cdk8s.ApiObject getApiObject()
getApiObject in class Resourcebase.Resource.apiObjectCopyright © 2021. All rights reserved.