apache / apisix

The Cloud-Native API Gateway
https://apisix.apache.org/blog/
Apache License 2.0
14.51k stars 2.52k forks source link

feature: Managing and configuring Apisix (CP and DP) via Kubernetes Operator #10546

Open nightguide opened 11 months ago

nightguide commented 11 months ago

Description

Hi all!

I have some idea about improving Apisix for use in Kubernetes

Сomposite architecture is good, but it has certain disadvantages in Kubernetes.

Dataplane in composite mode (Apisix) only receives changes to its configuration, but does not change configuration of Kubernetes resources: Deployment, Services, ConfigMaps, etc.

For example:

No possibility to change the number of Dataplane and ControlPlane replicas via CustomResource (CR)

No possibility to configure an additional TCP/UDP ports, which will additionally require a change in the Service resource K8S

No possibility to connect external configurations from ConfigMap

No possibility to easily and simply configure and update version apisix on dataplane instances

I think it would be nice to look towards the Operator SDK, which would allow the use of CR to configure and deploy dataplane and controlplane instances with Apisix.

This approach will not only allow to configure dataplane instances, but will also allow to manage Kubernetes resources for Apisix.

I think this approach will be more Kubernetes native

Have you thought about this?

p.s Kong API Gateway has a similar solution, see:

https://docs.konghq.com/gateway-operator/1.0.x/

https://docs.konghq.com/gateway/latest/production/deployment-topologies/hybrid-mode/

We love APISIX for its functionality and flexibility.

Please consider this functionality.

This will really be a killer feature that will be used.

Thank you.

shreemaan-abhishek commented 11 months ago

@Revolyssup can this be a part of ingress-controlller? Or would this be an entirely new project?

Revolyssup commented 11 months ago

@shreemaan-abhishek ingress-controller is designed purely as a controller and not operator so essentially this is a proposal for apisix-operator for Kubernetes, a new project.