container

package module
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 27, 2026 License: BSD-2-Clause Imports: 6 Imported by: 0

README

container

Container provides support for running containers in Go tests.

Documentation

Overview

Package container provides support for starting and stoping containers for running tests.

The container engine depends on the host OS.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Logs

func Logs(id string) []byte

Logs outputs logs from the running docker container.

func Stop

func Stop(id string) error

Stop stops and removes the specified container.

Types

type Container

type Container struct {
	ID   string
	Host string // IP:Port
}

Container tracks information about the container started for tests.

func Start

func Start(image, port string, args ...string) (*Container, error)

Start starts the specified container for running tests.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL