An open API service indexing awesome lists of open source software.

https://github.com/sunary/aku

grpc/http API gateway
https://github.com/sunary/aku

api-gateway crd grpc k8s

Last synced: about 1 month ago
JSON representation

grpc/http API gateway

Awesome Lists containing this project

README

          

# aku

API gateway that aggregates multiple backend services behind a single endpoint. You define which APIs to expose using Kubernetes custom resources (declarative configuration), following a [domain-oriented microservice](https://www.uber.com/en-SG/blog/microservice-architecture/) style.

## Install

1. **Install the Aku CRD**

```shell
kubectl apply -f artifacts/crd-aku.yaml
```

2. **Create an Aku resource**

```shell
kubectl apply -f artifacts/aku.yaml
```

Example `aku.yaml`:

```yaml
apiVersion: configuration.aku.vn/v1alpha1
kind: Aku
metadata:
name: aku
spec:
deploymentName: aku
replicas: 1
routeMap:
- name: open-prefix-public-path
overridePath: /api/v1/your-service/public
upstream_path: /public
- name: open-prefix/user-path
overridePath: /api/v1/your-service/user
upstream_path: /user
methodMap:
- name: open-only-public-method
proto_service: pb.ProtoService
allow:
- PublicMethod
- name: open-all-method-except-private
proto_service: pb.OtherProtoService
disallow:
- PrivateMethod
```

3. Deploy the aku gateway and assign it a `ClusterRole` so it can watch Aku resources.