MCPcopy Index your code
hub / github.com/docker/docker-py / create_endpoint_config

Method create_endpoint_config

docker/api/container.py:645–679  ·  view source on GitHub ↗

Create an endpoint config dictionary to be used with :py:meth:`create_networking_config`. Args: aliases (:py:class:`list`): A list of aliases for this endpoint. Names in that list can be used within the network to reach the contai

(self, *args, **kwargs)

Source from the content-addressed store, hash-verified

643 return NetworkingConfig(*args, **kwargs)
644
645 def create_endpoint_config(self, *args, **kwargs):
646 """
647 Create an endpoint config dictionary to be used with
648 :py:meth:`create_networking_config`.
649
650 Args:
651 aliases (:py:class:`list`): A list of aliases for this endpoint.
652 Names in that list can be used within the network to reach the
653 container. Defaults to ``None``.
654 links (dict): Mapping of links for this endpoint using the
655 ``{'container': 'alias'}`` format. The alias is optional.
656 Containers declared in this dict will be linked to this
657 container using the provided alias. Defaults to ``None``.
658 ipv4_address (str): The IP address of this container on the
659 network, using the IPv4 protocol. Defaults to ``None``.
660 ipv6_address (str): The IP address of this container on the
661 network, using the IPv6 protocol. Defaults to ``None``.
662 link_local_ips (:py:class:`list`): A list of link-local (IPv4/IPv6)
663 addresses.
664 driver_opt (dict): A dictionary of options to provide to the
665 network driver. Defaults to ``None``.
666
667 Returns:
668 (dict) An endpoint config.
669
670 Example:
671
672 >>> endpoint_config = client.api.create_endpoint_config(
673 aliases=['web', 'app'],
674 links={'app_db': 'db', 'another': None},
675 ipv4_address='132.65.0.123'
676 )
677
678 """
679 return EndpointConfig(self._version, *args, **kwargs)
680
681 @utils.check_resource('container')
682 def diff(self, container):

Calls 1

EndpointConfigClass · 0.85