BundlingOptions
Bundling options.
Initializer
import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore"
&alicloudroscdkcore.BundlingOptions {
Image: github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore.DockerImage,
BundlingFileAccess: github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore.BundlingFileAccess,
Command: *[]*string,
Entrypoint: *[]*string,
Environment: *map[string]*string,
Local: github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore.ILocalBundling,
Network: *string,
OutputType: github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore.BundlingOutput,
Platform: *string,
SecurityOpt: *string,
User: *string,
Volumes: *[]github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore.DockerVolume,
VolumesFrom: *[]*string,
WorkingDirectory: *string,
}
Properties
Name | Type | Description |
---|---|---|
Image |
DockerImage |
The Docker image where the command will run. |
BundlingFileAccess |
BundlingFileAccess |
The access mechanism used to make source files available to the bundling container and to return the bundling output back to the host. |
Command |
[]string |
The command to run in the Docker container. |
Entrypoint |
[]string |
The entrypoint to run in the Docker container. |
Environment |
map[string]string |
The environment variables to pass to the Docker container. |
Local |
ILocalBundling |
Local bundling provider. |
Network |
*string |
Docker Networking options. |
OutputType |
BundlingOutput |
The type of output that this bundling operation is producing. |
Platform |
*string |
Platform to build for. Requires Docker Buildx. |
SecurityOpt |
*string |
Security configuration when running the docker container. |
User |
*string |
The user to use when running the Docker container. |
Volumes |
*[]DockerVolume |
Additional Docker volumes to mount. |
VolumesFrom |
[]string |
Where to mount the specified volumes from. |
WorkingDirectory |
*string |
Working directory inside the Docker container. |
Image
Required
Image DockerImage
- Type: DockerImage
The Docker image where the command will run.
BundlingFileAccess
Optional
BundlingFileAccess BundlingFileAccess
- Type: BundlingFileAccess
- Default: BundlingFileAccess.BIND_MOUNT
The access mechanism used to make source files available to the bundling container and to return the bundling output back to the host.
Command
Optional
Command *[]*string
- Type: []string
- Default: run the command defined in the image
The command to run in the Docker container.
Example value: ['npm', 'install']
Entrypoint
Optional
Entrypoint *[]*string
- Type: []string
- Default: run the entrypoint defined in the image
The entrypoint to run in the Docker container.
Example value: ['/bin/sh', '-c']
https://docs.docker.com/engine/reference/builder/#entrypoint
Environment
Optional
Environment *map[string]*string
- Type: map[string]string
- Default: no environment variables.
The environment variables to pass to the Docker container.
Local
Optional
Local ILocalBundling
- Type: ILocalBundling
- Default: bundling will only be performed in a Docker container
Local bundling provider.
The provider implements a method tryBundle()
which should return true
if local bundling was performed. If false
is returned, docker bundling
will be done.
Network
Optional
Network *string
- Type: *string
- Default: no networking options
Docker Networking options.
OutputType
Optional
OutputType BundlingOutput
- Type: BundlingOutput
- Default: BundlingOutput.AUTO_DISCOVER
The type of output that this bundling operation is producing.
Platform
Optional
Platform *string
- Type: *string
- Default: no platform specified (the current machine architecture will be used)
Platform to build for. Requires Docker Buildx.
Specify this property to build images on a specific platform.
SecurityOpt
Optional
SecurityOpt *string
- Type: *string
- Default: no security options
Security configuration when running the docker container.
User
Optional
User *string
- Type: *string
- Default: uid:gid of the current user or 1000:1000 on Windows
The user to use when running the Docker container.
user | user:group | uid | uid:gid | user:gid | uid:group
Volumes
Optional
Volumes *[]DockerVolume
- Type: *[]DockerVolume
- Default: no additional volumes are mounted
Additional Docker volumes to mount.
VolumesFrom
Optional
VolumesFrom *[]*string
- Type: []string
- Default: no containers are specified to mount volumes from
Where to mount the specified volumes from.
WorkingDirectory
Optional
WorkingDirectory *string
- Type: *string
- Default: /asset-input
Working directory inside the Docker container.