@Generated(value="jsii-pacmak/1.43.0 (build b69a797)", date="2021-11-15T00:20:48.981Z") @Stability(value=Stable) public class Container extends software.amazon.jsii.JsiiObject
| Modifier and Type | Class and Description |
|---|---|
static class |
Container.Builder
A fluent builder for
Container. |
| Modifier | Constructor and Description |
|---|---|
|
Container(ContainerProps props) |
protected |
Container(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Container(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
void |
addEnv(String name,
EnvValue value)
Add an environment value to the container.
|
List<String> |
getArgs()
Arguments to the entrypoint.
|
List<String> |
getCommand()
Entrypoint array (the command to execute when the container starts).
|
Map<String,EnvValue> |
getEnv()
The environment variables for this container.
|
String |
getImage()
The container image.
|
ImagePullPolicy |
getImagePullPolicy()
Image pull policy for this container.
|
List<VolumeMount> |
getMounts()
Volume mounts configured for this container.
|
String |
getName()
The name of the container.
|
Number |
getPort()
The port this container exposes.
|
String |
getWorkingDir()
The working directory inside the container.
|
void |
mount(String path,
Volume volume)
Mount a volume to a specific path so that it is accessible by the container.
|
void |
mount(String path,
Volume volume,
MountOptions options)
Mount a volume to a specific path so that it is accessible by the container.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected Container(software.amazon.jsii.JsiiObjectRef objRef)
protected Container(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public Container(@NotNull
ContainerProps props)
props - This parameter is required.@Stability(value=Stable)
public void addEnv(@NotNull
String name,
@NotNull
EnvValue value)
The variable value can come from various dynamic sources such a secrets of config maps.
name - - The variable name. This parameter is required.value - - The variable value. This parameter is required.EnvValue.fromXXX@Stability(value=Stable)
public void mount(@NotNull
String path,
@NotNull
Volume volume,
@Nullable
MountOptions options)
Every pod that is configured to use this container will autmoatically have access to the volume.
path - - The desired path in the container. This parameter is required.volume - - The volume to mount. This parameter is required.options - @Stability(value=Stable)
public void mount(@NotNull
String path,
@NotNull
Volume volume)
Every pod that is configured to use this container will autmoatically have access to the volume.
path - - The desired path in the container. This parameter is required.volume - - The volume to mount. This parameter is required.@Stability(value=Stable) @NotNull public Map<String,EnvValue> getEnv()
Returns a copy. To add environment variables use addEnv().
@Stability(value=Stable) @NotNull public String getImage()
@Stability(value=Stable) @NotNull public ImagePullPolicy getImagePullPolicy()
@Stability(value=Stable) @NotNull public List<VolumeMount> getMounts()
@Stability(value=Stable) @NotNull public String getName()
@Stability(value=Stable) @Nullable public List<String> getArgs()
@Stability(value=Stable) @Nullable public List<String> getCommand()
@Stability(value=Stable) @Nullable public Number getPort()
@Stability(value=Stable) @Nullable public String getWorkingDir()
Copyright © 2021. All rights reserved.