Goma Gateway – 轻量级、高性能的 API 网关和反向代理,具有声明式配置、强大的中间件,并支持 REST、GraphQL、TCP、UDP、
Goma Gateway – 轻量级、高性能的 API 网关和反向代理,具有声明式配置、强大的中间件,并支持 REST、GraphQL、TCP、UDP、
____
/ ___| ___ _ __ ___ __ _
| | _ / _ \| '_ ` _ \ / _` |
| |_| | (_) | | | | | | (_| |
\____|\___/|_| |_| |_|\__,_|
:: Goma Gateway :: - ()
Goma Gateway is a high-performance, security-focused API Gateway built for modern developers and cloud-native environments. With a powerful feature set, intuitive configuration, and first-class support for observability, Goma helps you route, secure, and scale traffic effortlessly.
**Why "Goma"? **
The project takes its name from Goma, a resilient city in the eastern Democratic Republic of Congo that serves as a vital crossroads connecting diverse regions. Like its namesake, Goma Gateway acts as a strategic entry point managing, securing, and directing the flow of API traffic that connects your services.
Architecture:
Documentation: Documentation
Source Code: Goma Gateway on GitHub
Docker Image: jkaninda/goma-gateway
Goma Admin(Control Plane): Goma Admin
HTTP Provider: Goma HTTP Provider
Docker Provider: Goma Docker Provider
Kubernetes Provider: Kubernetes Provider
Kubernetes Operator: Kubernetes Operator
Miabi PaaS: Miabi PaaS
Goma Gateway is a modern, developer-friendly API Gateway built for simplicity, security, and scale. More than just a reverse proxy, it streamlines service infrastructure management with declarative configuration and enterprise-grade features.
Declarative YAML-based configuration
Flexible routing for domains, hosts, paths, WebSocket, gRPC, TCP/UDP
Multi-domain & multi-service support in one config
Reverse proxy with backend abstraction
Traffic control: rate limiting, load balancing, health checks
Canary Deployments: Safely roll out new versions of your services with advanced canary deployment strategies:
Enterprise-grade security without the enterprise complexity
More than just a reverse proxy, Goma Gateway streamlines your services with declarative configuration and enterprise-grade features.
Write clear YAML for routes, middleware, policies, and TLS. Supports single-file or multi-file setups, intuitive and maintainable.
Handle REST APIs, WebSocket, gRPC, intelligent host & path routing.
Apply changes instantly without restarts — perfect for CI/CD pipelines.
Perfect for: Public APIs, internal microservices, legacy modernization, or any project requiring secure, scalable traffic management.
Get started with Goma Gateway in just a few steps. This guide covers generating a configuration file, customizing it, validating your setup, and running the gateway with Docker.
Before you begin, ensure you have:
Run the following command to create a default configuration file (config.yml):
docker run --rm --name goma-gateway \
-v "${PWD}/config:/etc/goma/" \
jkaninda/goma-gateway config init --output /etc/goma/config.ymlThis will generate the configuration under ./config/config.yml.
Edit ./config/config.yml to define your routes, middlewares, backends, and other settings.
Check the configuration for errors before starting the server:
docker run --rm --name goma-gateway \
-v "${PWD}/config:/etc/goma/" \
jkaninda/goma-gateway config check --config /etc/goma/config.ymlFix any reported issues before proceeding.
Launch the server with your configuration and Let's Encrypt volumes:
docker run --rm --name goma-gateway \
-v "${PWD}/config:/etc/goma/" \
-v "${PWD}/letsencrypt:/etc/letsencrypt" \
-p 8080:8080 \
-p 8443:8443 \
jkaninda/goma-gateway --config /etc/goma/config.ymlBy default, Goma Gateway listens on:
web entry point)webSecure entry point)To run on standard HTTP/HTTPS ports, update your config file:
version: 2
gateway:
entryPoints:
web:
address: ":80"
webSecure:
address: ":443"Start the container with:
docker run --rm --name goma-gateway \
-v "${PWD}/config:/etc/goma/" \
-v "${PWD}/letsencrypt:/etc/letsencrypt" \
-p 80:80 \
-p 443:443 \
jkaninda/goma-gateway --config /etc/goma/config.ymlGoma Gateway exposes the following endpoints:
Gateway health:
/readyz/healthzRoutes health:
/healthz/routesA simple docker-compose setup:
config.yaml
…compose.yaml
services:
goma-gateway:
image: jkaninda/goma-gateway
command: -c /etc/goma/config.yaml
ports:
- "80:80"
- "443:443"
volumes:
- ./config:/etc/goma/
- ./letsencrypt:/etc/letsencrypt
api-example:
image: jkaninda/okapi-exampleVisit http://localhost/docs to see the documentation
Goma Gateway intentionally does not include a built-in Docker provider or user interface in order to remain lightweight, modular, and focused on its role as a data plane.
These capabilities are provided by Goma Admin, which acts as the control plane and includes native support for a Docker provider. This allows automatic generation of gateway configuration from container labels.
Goma Admin is a web-based control plane for managing Goma Gateway configurations.
It provides a structured and user-friendly interface to define routes, middleware, and TLS settings without requiring manual editing of YAML configuration files.
When deploying services with Docker Compose or Docker Swarm, the Goma Docker Provider automatically generates gateway configuration from container labels.
This model is similar to Traefik, where routing rules, services, and middleware are defined directly on containers through labels.
…kubectl apply -f https://raw.githubusercontent.com/jkaninda/goma-gateway/main/examples/k8s-basic-deployment.yamlFor declarative, GitOps-friendly deployments, use the Goma Gateway Operator, which manages Gateway, Route, and Middleware custom resources.
1. Install the operator and its CRDs:
kubectl apply -f https://raw.githubusercontent.com/jkaninda/goma-operator/main/dist/install.yaml2. Apply a minimal stack (Gateway + Middleware + Route):
…Or apply a ready-made example directly:
kubectl apply -f https://raw.githubusercontent.com/jkaninda/goma-gateway/main/examples/kubernetes-operator-basic.yamlFor a production-style stack (LoadBalancer, ACME, HPA, JWT, weighted backends), see kubernetes-advanced.yaml and the Operator Manual.
The Goma HTTP Provider exposes a REST API for managing routes, middleware, and gateway configuration dynamically.
It’s ideal for:
See: Goma HTTP Provider
Goma Gateway offers built-in monitoring capabilities to help you track the health, performance, and behavior of your gateway and its routes. Metrics are exposed in a Prometheus-compatible format and can be visualized using tools like Prometheus and Grafana.
A prebuilt Grafana dashboard is available to visualize metrics from Goma Gateway.
You can import it using dashboard ID: 23799
For production deployments, use the example from the link below:
Miabi is a self-hosted
暂无开放 Issues,或尚未同步最近议题。