Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RunPostgreInM ¶
Types ¶
type PostgreInDocker ¶
type PostgreInDocker interface { // GetAddr returns the address to connect to GetAddr() string // Finish will stop the container Finish() error // GetLogs returns the logs of the container. It is useful for debugging GetLogs() string // WaitUntilReady will wait until the container is ready to accept connections WaitUntilReady() error }
PostgreInDocker is an interface to manage a postgres container
func NewPostgreInDocker ¶
func NewPostgreInDocker(cfg PostgresConfig) (PostgreInDocker, error)
type PostgresConfig ¶
type PostgresConfig struct { // DockerEndpoint is the endpoint to connect to docker DockerEndpoint string // MigrationPath is the path to the sql migration files MigrationPath string // DebugMode will print the logs of the container DebugMode bool // ExplicitWait is the flag to enable the explicit wait ExplicitWait bool // PostgresVersion is the version of postgres to use PostgresVersion string // ContainerNameSuffix is the suffix to add to the container name ContainerNameSuffix string }
Click to show internal directories.
Click to hide internal directories.