Ejemplo n.º 1
0
func (s *RunSuite) GetContainersByProject(c *C, project string) []dockerclient.APIContainers {
	client := GetClient(c)
	containers, err := docker.GetContainersByFilter(client, docker.PROJECT.Eq(project))

	c.Assert(err, IsNil)

	return containers
}
Ejemplo n.º 2
0
func (s *CliSuite) GetContainersByProject(c *C, project string) []types.Container {
	client := GetClient(c)
	containers, err := docker.GetContainersByFilter(context.Background(), client, labels.PROJECT.Eq(project))

	c.Assert(err, IsNil)

	return containers
}