Documentation ¶
Overview ¶
Package mobynet implements the discovery of Docker network names and container/service labels on these networks, using the Docker API.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DiscoverAttachedNames ¶
func DiscoverAttachedNames(ctx context.Context, moby *client.Client, centerID string) ([]dig.DockerNetwork, string, error)
DiscoverAttachedNames takes on the position of the “origin” or “center” container identified by centerID and then inspects the networks attached to this container 0. It then queries the containers attached to the attached networks for their container names and aliases.
This implementation even works correctly in situations with multiple Docker networks having the same name, yet different IDs. Docker networks are different from containers in that network names are not necessarily unambiguous, while container names always are.
Types ¶
This section is empty.