public static class DockerClient.BuildParam extends DockerClient.Param
build
method.Constructor and Description |
---|
BuildParam(String name,
String value) |
Modifier and Type | Method and Description |
---|---|
static DockerClient.BuildParam |
cpusetCpus(Integer cpusetCpus)
CPUs in which to allow execution, e.g.
|
static DockerClient.BuildParam |
cpuShares(Integer cpuShares)
CPU shares (relative weight).
|
static DockerClient.BuildParam |
create(String name,
String value)
Create a custom parameter.
|
static DockerClient.BuildParam |
dockerfile(Path dockerfile)
path within the build context to the Dockerfile.
|
static DockerClient.BuildParam |
forceRm()
Always remove intermediate containers.
|
static DockerClient.BuildParam |
memory(Integer memory)
Set memory limit for build.
|
static DockerClient.BuildParam |
name(String name)
Repository name (and optionally a tag) to be applied to the
resulting image in case of success.
|
static DockerClient.BuildParam |
noCache()
Do not use the cache when building the image.
|
static DockerClient.BuildParam |
pullNewerImage()
Always attempt to pull a newer version of the base image even if one exists locally.
|
static DockerClient.BuildParam |
quiet()
Suppress verbose build output.
|
static DockerClient.BuildParam |
remote(URI remote)
A Git repository URI or HTTP/HTTPS URI build source.
|
static DockerClient.BuildParam |
rm()
Remove intermediate containers after a successful build.
|
static DockerClient.BuildParam |
rm(boolean rm)
Control whether to remove intermediate containers after a successful build.
|
static DockerClient.BuildParam |
totalMemory(Integer totalMemory)
Total memory (memory + swap).
|
equals, hashCode, name, value
public static DockerClient.BuildParam name(String name)
You could also pass the name explicitly to DockerClient.build(Path, String, BuildParam...)
or one of the other build methods that takes an explicit name.
name
- A name to apply to the imagepublic static DockerClient.BuildParam create(String name, String value)
name
- custom namevalue
- custom valuepublic static DockerClient.BuildParam quiet()
public static DockerClient.BuildParam rm()
public static DockerClient.BuildParam rm(boolean rm)
rm
- Whether to removepublic static DockerClient.BuildParam noCache()
public static DockerClient.BuildParam forceRm()
public static DockerClient.BuildParam pullNewerImage()
public static DockerClient.BuildParam dockerfile(Path dockerfile)
remote(URI)
is specified and points to an individual filename.
You could also pass the dockerfile path explicitly to
DockerClient.build(Path, String, String, ProgressHandler, BuildParam...)
or one of the other build methods that takes an explicit dockerfile path.
dockerfile
- Path to the dockerfile in the build context.public static DockerClient.BuildParam remote(URI remote)
remote
- A Git repository URI or HTTP/HTTPS URI build source.public static DockerClient.BuildParam memory(Integer memory)
memory
- Memory limit for build, in bytes.public static DockerClient.BuildParam totalMemory(Integer totalMemory)
totalMemory
- Total memory (memory + swap) in bytes.public static DockerClient.BuildParam cpuShares(Integer cpuShares)
cpuShares
- CPU shares (relative weight).public static DockerClient.BuildParam cpusetCpus(Integer cpusetCpus)
0-3
, 0,1
.cpusetCpus
- CPUs in which to allow executionCopyright © 2018. All rights reserved.