public class DockerService extends Object
Constructor and Description |
---|
DockerService(Config config,
InternalPreferences preferences) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
String |
execCommandInContainer(String containerId,
String... command) |
boolean |
existsImage(String imageId) |
String |
getBindPort(String containerId,
String exposed) |
Config |
getConfig() |
com.spotify.docker.client.DockerClient |
getDockerClient() |
String |
getDockerDefaultSocket() |
int |
getDockerPollTimeMs() |
int |
getDockerWaitTimeoutSec() |
String |
getHost(String containerId,
String network) |
void |
pullImage(String imageId) |
void |
removeContainer(String containerId) |
String |
startContainer(DockerContainer dockerContainer) |
void |
stopAndRemoveContainer(String containerId,
String imageId) |
void |
stopContainer(String containerId) |
void |
updateDockerClient(String url) |
public DockerService(Config config, InternalPreferences preferences)
public String getHost(String containerId, String network) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public String startContainer(DockerContainer dockerContainer) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public String execCommandInContainer(String containerId, String... command) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public String getBindPort(String containerId, String exposed) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public void pullImage(String imageId) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public boolean existsImage(String imageId)
public void stopContainer(String containerId) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public void removeContainer(String containerId) throws com.spotify.docker.client.exceptions.DockerException, InterruptedException
com.spotify.docker.client.exceptions.DockerException
InterruptedException
public String getDockerDefaultSocket()
public int getDockerWaitTimeoutSec()
public int getDockerPollTimeMs()
public com.spotify.docker.client.DockerClient getDockerClient()
public void close()
public void updateDockerClient(String url)
public Config getConfig()
Copyright © 2019. All rights reserved.