Interface CustomCommandOptions
- All Superinterfaces:
AssetOptions,AssetOptions,FileCopyOptions,software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
CustomCommandOptions.Jsii$Proxy
@Generated(value="jsii-pacmak/1.119.0 (build 1634eac)",
date="2025-11-13T16:10:08.478Z")
@Stability(Stable)
public interface CustomCommandOptions
extends software.amazon.jsii.JsiiSerializable, AssetOptions
Options for creating
AssetCode with a custom command, such as running a buildfile.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;
import software.amazon.awscdk.services.iam.*;
import software.amazon.awscdk.services.lambda.*;
import software.amazon.awscdk.interfaces.kms.*;
Object commandOptions;
DockerImage dockerImage;
IGrantable grantable;
IKeyRef keyRef;
ILocalBundling localBundling;
CustomCommandOptions customCommandOptions = CustomCommandOptions.builder()
.assetHash("assetHash")
.assetHashType(AssetHashType.SOURCE)
.bundling(BundlingOptions.builder()
.image(dockerImage)
// the properties below are optional
.bundlingFileAccess(BundlingFileAccess.VOLUME_COPY)
.command(List.of("command"))
.entrypoint(List.of("entrypoint"))
.environment(Map.of(
"environmentKey", "environment"))
.local(localBundling)
.network("network")
.outputType(BundlingOutput.ARCHIVED)
.platform("platform")
.securityOpt("securityOpt")
.user("user")
.volumes(List.of(DockerVolume.builder()
.containerPath("containerPath")
.hostPath("hostPath")
// the properties below are optional
.consistency(DockerVolumeConsistency.CONSISTENT)
.build()))
.volumesFrom(List.of("volumesFrom"))
.workingDirectory("workingDirectory")
.build())
.commandOptions(Map.of(
"commandOptionsKey", commandOptions))
.deployTime(false)
.displayName("displayName")
.exclude(List.of("exclude"))
.followSymlinks(SymlinkFollowMode.NEVER)
.ignoreMode(IgnoreMode.GLOB)
.readers(List.of(grantable))
.sourceKMSKey(keyRef)
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forCustomCommandOptionsstatic final classAn implementation forCustomCommandOptions -
Method Summary
Modifier and TypeMethodDescriptionstatic CustomCommandOptions.Builderbuilder()options that are passed to the spawned process, which determine the characteristics of the spawned process.Methods inherited from interface software.amazon.awscdk.AssetOptions
getAssetHash, getAssetHashType, getBundlingMethods inherited from interface software.amazon.awscdk.services.s3.assets.AssetOptions
getDeployTime, getDisplayName, getReaders, getSourceKMSKeyMethods inherited from interface software.amazon.awscdk.FileCopyOptions
getExclude, getFollowSymlinks, getIgnoreModeMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getCommandOptions
options that are passed to the spawned process, which determine the characteristics of the spawned process.Default: : see `child_process.SpawnSyncOptions` (https://nodejs.org/api/child_process.html#child_processspawnsynccommand-args-options).
-
builder
- Returns:
- a
CustomCommandOptions.BuilderofCustomCommandOptions
-