protected function isContainerRunning($container)
    {
        /** @var ResultData $result */
        $result = $this->runSilentCommand(
            $this->taskExec("docker inspect -f {{.State.Running}} {$container}")
        );

        return $result->getExitCode() === Resultdata::EXITCODE_OK
            && $result->getMessage() == 'true';
    }
protected function isContainerRunning($container)
    {
        /** @var ResultData $result */
        $result = $this->runSilentCommand(
            $this->taskExec("docker inspect -f {{.State.Running}} {$container}")
        );

        return $result->getExitCode() === Resultdata::EXITCODE_OK
            && $result->getMessage() == 'true';
    }
protected function isContainerRunning ( $ container ) { /** @var ResultData $result */ $ result = $ this -> runSilentCommand ( $ this -> taskExec ( "docker inspect -f {{.State.Running}} {$container}" ) ) ; return $ result -> getExitCode ( ) === Resultdata :: EXITCODE_OK && $ result -> getMessage ( ) == 'true' ; }
Determine if docker container is running.

@param string $container
The container name or identifier.

@return bool
Determine if docker container is running .