I want to create and run docker using docker java client. I want running something like this:
docker logs -f selenium-hub
How to implement this command on docker-java client? Here is my code so far:
result = dockerClient.logContainerCmd(container.getId())
.withStdErr(true)
.withStdOut(true)
.withFollowStream(true)
.withTailAll()
.exec(logContainerResultCallback);
try {
logContainerResultCallback.awaitCompletion();
} catch (InterruptedException e) {
throw new BaseException(e.getMessage());
}catch (Exception e){
throw new BaseException(e.getMessage());
}
break;
why it didn't show like docker show? docker show like
"host": null,
"port": 4444,
"prioritizer": null,
"capabilityMatcher": "org.openqa.grid.internal.utils.DefaultCapabilityMatcher"
"throwOnCapabilityNotPresent": true,
"newSessionWaitTimeout": -1,
"jettyMaxThreads": -1,
"nodePolling": 5000,
"cleanUpCycle": 5000,
"timeout": 30000,
"browserTimeout": 0,
"maxSession": 5,
"unregisterIfStillDownAfter": 30000
but it didn't show in java.
please help me. I'm newbie in docker. I want to implement this in java. thanks a lot