code: public function containerExists($containerName = '')
      {
          Assertion::notEmpty($containerName, 'Container name is not specified');
          self::assertValidContainerName($containerName);
  
          // List containers
          $containers = $this->listContainers($containerName, 1);
          foreach ($containers as $container) {
              if ($container->Name == $containerName) {
                  return true;
              }
          }
  
          return false;
      }
docs: Check if a container exists
  
  @param string $containerName Container name
  @return boolean