Class DynamicDockerContainer
java.lang.Object
org.jenkinsci.test.acceptance.docker.DockerContainer
org.jenkinsci.test.acceptance.docker.DynamicDockerContainer
- All Implemented Interfaces:
Closeable
,AutoCloseable
A DockerContainer whose
Dockerfile
is not static but requires some knowledge of the environment it is going to run in.
Before the image is created process(String)
will be called which can be used to replace place holders with given values or manipulate the docker file in anyother way.-
Constructor Summary
-
Method Summary
Methods inherited from class org.jenkinsci.test.acceptance.docker.DockerContainer
assertRunning, close, cp, getCid, getIpAddress, getLogfile, getPid, inspect, ipBound, ipUdpBound, ipv6Enabled, port, resource, sharingHostDockerService, toString, udpPort
-
Constructor Details
-
DynamicDockerContainer
public DynamicDockerContainer()
-
-
Method Details
-
process
Manipulates the provided Dockerfile contents. This method replaces any occurrence of@@DOCKER_HOST@@
with the ip address of the machine running docker.- Parameters:
contents
- the original contents of the Dockerfile- Returns:
- a String with the new contents of the Dockerfile
-