Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Beta support for running consul-k8s without client agents #1552

Merged
merged 15 commits into from
Sep 28, 2022

Commits on Sep 27, 2022

  1. Initial support for agentless (#1267)

    Add initial support for the basic service mesh running with agentless.
    
    * Update connect-inject deployment to talk to consul servers (currently only in-cluster servers are supported; external servers support will come in a later PR)
    * Update endpoints controller to register and deregister services and health checks in the catalog and stop using agent APIs
    * Update connect-init command to take the -node-name flag so that it can search for services within a given node using catalog APIs
    * Add k8s probes to the envoy container
    * Provide -node-name flag to the consul connect envoy command so that we can generate correct configuration
    * Selectively disable acceptance tests that don't yet work in this configuration
    * Disable consul clients by default
    ishustava authored and jmurret committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    c897e70 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    0bc860a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    b6a8423 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    666a83c View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    61ab869 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    01f5317 View commit details
    Browse the repository at this point in the history
  7. Register mesh-gateways using the endpoints controller. (#1464)

    * Register mesh-gateways using the endpoints controller.
    - Use consul-dataplane to configure the mesh-gateway proxy and remove envoy container.
    - Remove instances of client and auto-encrypt from the deployment.
    * Replace ioutil.ReadFile with os.ReadFile
    thisisnotashwin authored and jmurret committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    51c3585 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    31125b4 View commit details
    Browse the repository at this point in the history
  9. agentless: integrate connect-inject with consul-server-connection-man…

    …ager (#1502)
    
    * Introduce new set of Consul flags that will be used by all consul-k8s commands
    * Use consul-server-connection-manager to discover servers and use up-to-date
      server IP every time we need to make an API request.
    ishustava authored and jmurret committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    b82ac7f View commit details
    Browse the repository at this point in the history
  10. Register Terminating Gateways with Endpoints Controller (#1469)

    - Added a `terminating-gateway-service.yaml` template. In order to register the deployment with the Endpoints Controller, a "dummy" service must exist so that a Kubernetes endpoint object is created, triggering the Endpoints Controller reconcile loop.
    - Modified the `terminating-gateway-deployment.yaml` template:
      - Added a "managed by" label.
      - Added annotations to configure the behavior of the Endpoints Controller during registration.
      - Removed the `copy-consul-bin` init container.
      - Changed the `terminating-gateway-init` init container to use `connect-init` instead of `acl-init` as the client `acl-init` talked to will no longer exist in agentless.
      - Removed the `preStop` hook from the `terminating-gateway` container.
      - Removed the `consul-sidecar` container in preparation for the blessings of the Consul Dataplane. 
    - Removed BATS tests which covered features no longer present in agentless.
    - Added BATS tests for `terminating-gateway-service` and for Consul namespace handling in `terminating-gateway-deployment`.
    - Added annotation `consul.hashicorp.com/terminating-gateway-namespace` to configure which Consul namespace a terminating gateway will be placed in when using Consul Enterprise.
    - Modified the Endpoints Controller to register terminating gateways
      - Added a `switch` to the `createGatewayRegistrations` method which handles configuration of the endpoint particular to the terminating gateway.
      - Added unit tests which verify the registrations created by `createGatewayRegistrations` is correct.
      - Added a unit test to verify the the `Reconcile` method does register the endpoint.
    
    Co-authored-by: Iryna Shustava <[email protected]>
    Co-authored-by: Ashwin Venkatesh <[email protected]>
    Co-authored-by: Ashwin Venkatesh <[email protected]>
    4 people authored and jmurret committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    d1ee841 View commit details
    Browse the repository at this point in the history
  11. agentless: integrate consul-server-connection-manager to connect-init…

    … command (#1520)
    
    * Introduce new set of Consul flags that will be used by all consul-k8s commands
    * Use consul-server-connection-manager to discover servers and use up-to-date
      server IP every time we need to make an API request.
    
    Co-authored-by: Ashwin Venkatesh <[email protected]>
    2 people authored and jmurret committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    f757bfb View commit details
    Browse the repository at this point in the history
  12. rebasing conflicts

    jmurret committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    2ea0255 View commit details
    Browse the repository at this point in the history
  13. agentless: enable admin partitions with agentless (#1543)

    * integrate partition-init job with consul-server-connection-manager
    * integrate controller with consul-server-connection-manager
    * modify partition token to be be able read all services so that it works with connection manager
    ishustava authored Sep 27, 2022
    Configuration menu
    Copy the full SHA
    711f1f3 View commit details
    Browse the repository at this point in the history

Commits on Sep 28, 2022

  1. Register Ingress Gateway with Endpoints Controller (#1544)

    - Use consul-dataplane instead of envoy.
    thisisnotashwin authored Sep 28, 2022
    Configuration menu
    Copy the full SHA
    85d29fd View commit details
    Browse the repository at this point in the history
  2. Use Consul Dataplane for Terminating Gateways (#1534)

    Thomas Eckert authored Sep 28, 2022
    Configuration menu
    Copy the full SHA
    0805258 View commit details
    Browse the repository at this point in the history