Class CliCredentialsStackSynthesizer
A synthesizer that uses conventional asset locations, but not conventional deployment roles.
Inherited Members
Namespace: Amazon.CDK
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CliCredentialsStackSynthesizer : StackSynthesizer, IReusableStackSynthesizer, IBoundStackSynthesizer, IStackSynthesizer
Syntax (vb)
Public Class CliCredentialsStackSynthesizer
Inherits StackSynthesizer
Implements IReusableStackSynthesizer, IBoundStackSynthesizer, IStackSynthesizer
Remarks
Instead of assuming the bootstrapped deployment roles, all stack operations will be performed using the CLI's current credentials.
Be aware that your CLI credentials must be valid for the duration of the entire deployment. If you are using session credentials, make sure the session lifetime is long enough.
By default, expects the environment to have been bootstrapped with just the staging resources of the Bootstrap Stack V2 (also known as "modern bootstrap stack"). You can override the default names using the synthesizer's construction properties.
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK;
var cliCredentialsStackSynthesizer = new CliCredentialsStackSynthesizer(new CliCredentialsStackSynthesizerProps {
BucketPrefix = "bucketPrefix",
DockerTagPrefix = "dockerTagPrefix",
FileAssetsBucketName = "fileAssetsBucketName",
ImageAssetsRepositoryName = "imageAssetsRepositoryName",
Qualifier = "qualifier"
});
Synopsis
Constructors
CliCredentialsStackSynthesizer(ICliCredentialsStackSynthesizerProps) | |
CliCredentialsStackSynthesizer(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CliCredentialsStackSynthesizer(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
BootstrapQualifier | The qualifier used to bootstrap this stack. |
Methods
AddDockerImageAsset(IDockerImageAssetSource) | Register a Docker Image Asset. |
AddFileAsset(IFileAssetSource) | Register a File Asset. |
Bind(Stack) | Bind to the stack this environment is going to be used on. |
ReusableBind(Stack) | Produce a bound Stack Synthesizer for the given stack. |
Synthesize(ISynthesisSession) | Synthesize the associated stack to the session. |
Constructors
CliCredentialsStackSynthesizer(ICliCredentialsStackSynthesizerProps)
public CliCredentialsStackSynthesizer(ICliCredentialsStackSynthesizerProps props = null)
Parameters
CliCredentialsStackSynthesizer(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CliCredentialsStackSynthesizer(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CliCredentialsStackSynthesizer(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CliCredentialsStackSynthesizer(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
BootstrapQualifier
The qualifier used to bootstrap this stack.
public override string BootstrapQualifier { get; }
Property Value
System.String
Overrides
Methods
AddDockerImageAsset(IDockerImageAssetSource)
Register a Docker Image Asset.
public override IDockerImageAssetLocation AddDockerImageAsset(IDockerImageAssetSource asset)
Parameters
- asset IDockerImageAssetSource
Returns
Overrides
Remarks
Returns the parameters that can be used to refer to the asset inside the template.
The synthesizer must rely on some out-of-band mechanism to make sure the given files
are actually placed in the returned location before the deployment happens. This can
be by writing the instructions to the asset manifest (for use by the cdk-assets
tool),
by relying on the CLI to upload files (legacy behavior), or some other operator controlled
mechanism.
AddFileAsset(IFileAssetSource)
Register a File Asset.
public override IFileAssetLocation AddFileAsset(IFileAssetSource asset)
Parameters
- asset IFileAssetSource
Returns
Overrides
Remarks
Returns the parameters that can be used to refer to the asset inside the template.
The synthesizer must rely on some out-of-band mechanism to make sure the given files
are actually placed in the returned location before the deployment happens. This can
be by writing the instructions to the asset manifest (for use by the cdk-assets
tool),
by relying on the CLI to upload files (legacy behavior), or some other operator controlled
mechanism.
Bind(Stack)
Bind to the stack this environment is going to be used on.
public override void Bind(Stack stack)
Parameters
- stack Stack
Overrides
Remarks
Must be called before any of the other methods are called.
ReusableBind(Stack)
Produce a bound Stack Synthesizer for the given stack.
public virtual IBoundStackSynthesizer ReusableBind(Stack stack)
Parameters
- stack Stack
Returns
Remarks
This method may be called more than once on the same object.
Synthesize(ISynthesisSession)
Synthesize the associated stack to the session.
public override void Synthesize(ISynthesisSession session)
Parameters
- session ISynthesisSession