YARN-8791. Trim docker inspect output for line feed for STOPSIGNAL parsing.
Contributed by Chandni Singh
This commit is contained in:
parent
1824d5d1c4
commit
efdea85ad1
|
@ -1282,7 +1282,7 @@ public class DockerLinuxContainerRuntime implements LinuxContainerRuntime {
|
||||||
DockerInspectCommand.STATUS_TEMPLATE,
|
DockerInspectCommand.STATUS_TEMPLATE,
|
||||||
DockerInspectCommand.STOPSIGNAL_TEMPLATE}, delimiter);
|
DockerInspectCommand.STOPSIGNAL_TEMPLATE}, delimiter);
|
||||||
try {
|
try {
|
||||||
String output = executeDockerInspect(containerId, inspectCommand);
|
String output = executeDockerInspect(containerId, inspectCommand).trim();
|
||||||
|
|
||||||
if (!output.isEmpty()) {
|
if (!output.isEmpty()) {
|
||||||
String[] statusAndSignal = StringUtils.split(output, delimiter);
|
String[] statusAndSignal = StringUtils.split(output, delimiter);
|
||||||
|
|
Loading…
Reference in New Issue