@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:41.821Z") @Stability(value=Stable) public interface AssetOptions extends software.amazon.jsii.JsiiSerializable, AssetOptions, FileCopyOptions
Function.Builder.create(this, "Function")
.code(Code.fromAsset(join(__dirname, "my-python-handler"), AssetOptions.builder()
.bundling(BundlingOptions.builder()
.image(Runtime.PYTHON_3_9.getBundlingImage())
.command(List.of("bash", "-c", "pip install -r requirements.txt -t /asset-output && cp -au . /asset-output"))
.build())
.build()))
.runtime(Runtime.PYTHON_3_9)
.handler("index.handler")
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
AssetOptions.Builder
A builder for
AssetOptions |
static class |
AssetOptions.Jsii$Proxy
An implementation for
AssetOptions |
| Modifier and Type | Method and Description |
|---|---|
static AssetOptions.Builder |
builder() |
default List<IGrantable> |
getReaders()
A list of principals that should be able to read this asset from S3.
|
getAssetHash, getAssetHashType, getBundlinggetExclude, getFollowSymlinks, getIgnoreMode@Stability(value=Stable) @Nullable default List<IGrantable> getReaders()
You can use asset.grantRead(principal) to grant read permissions later.
Default: - No principals that can read file asset.
@Stability(value=Stable) static AssetOptions.Builder builder()
builder in interface AssetOptionsbuilder in interface FileCopyOptionsAssetOptions.Builder of AssetOptionsCopyright © 2022. All rights reserved.