def container_by_name(self, name):
        """
        Returns container with given name
        """
        if not name:
            return None

        # docker prepends a '/' to container names in the container dict
        name = '/'+name
        return next((container for container in self.containers(all=True)
                     if name in container['Names']), None)
Returns container with given name