TestcontainerEx.ToxiproxyContainer (testcontainer_ex v0.9.0)

Copy Markdown View Source

Provides functionality for creating and managing Toxiproxy container configurations.

Summary

Types

t()

@type t() :: %TestcontainerEx.ToxiproxyContainer{
  check_image: term(),
  image: term(),
  name: term(),
  reuse: term(),
  wait_timeout: term()
}

Functions

api_url(container)

configure_toxiproxy_ex(container)

control_port()

create_proxy(container, name, upstream, opts \\ [])

create_proxy_for_container(toxiproxy, name, target, target_port, opts \\ [])

default_image()

delete_proxy(container, name)

first_proxy_port()

list_proxies(container)

mapped_control_port(container)

new()

proxy_port_count()

reset(container)

with_check_image(config, check_image)

@spec with_check_image(t(), String.t() | Regex.t()) :: t()

Sets the check image regex (or string) used to validate the container image name before starting.

with_image(c, image)

with_name(config, name)

@spec with_name(t(), String.t()) :: t()

Sets the container name.

with_reuse(config, reuse)

@spec with_reuse(t(), boolean()) :: t()

Enables or disables container reuse.

with_wait_timeout(c, t)