-
Notifications
You must be signed in to change notification settings - Fork 326
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support a workaround for multi port pods by registering a Consul service per port, and by injecting init containers and envoy sidecars per port. Does not work for services with transparent proxy, metrics, or metrics merging. - Acceptance test for multiport - The multiport app is just http-echo listening on different ports in 2 containers - First, the test deploys `static-client` and `multiport`, with static-client having `multiport` and `multiport-admin` as upstreams. It checks that `static-client` can make connections to each service-- `multiport`, and `multiport-admin`. This is to test inbound connections for a multiport app. - Then the test deploys `static-server`, and checks that `multiport` can make a connection to `static-server`. This is to test outbound connections from a multiport app. Note that there is only 1 intention because all upstream connections are configured and go through the 1st service's envoy proxy. - Implementation for multiport - `handler` - uses the service name annotation to figure out if this is a multiport pod or not - inject a connect-init container and an envoy-sidecar container per port/service - mount all service account tokens not already on the pod. For any service whose service account is not already attached to the pod, this mounts a volume for that service account token. In container-init, these volumes are added as a container volumeMount so the service account token file can be passed to the connect-init command via `-bearer-token-file` - `container_init` -- update the template to pass in arguments specific to the multiport service - `envoy_sidecar` -- allow the bootstrap file path to have the service name in it for multiport services, and add `--base-id` since there could be multiple envoy sidecars. - `endpoints_controller`: the listener port should be 20000 for the first service, 20001 for the second, etc. Also only configures upstreams on first service port in a multiport pod. - `connect_init` command: when its a multiport app, add a filter to poll by service name, use the service specific bearertoken, acl-token-sink, and proxyid files
- Loading branch information
1 parent
ae206c9
commit 06ab056
Showing
33 changed files
with
1,637 additions
and
204 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.