https://github.com/calpa/kong-zeabur
π Kong Gateway DB-less template for Zeabur. One-click deployment of a lightweight, high-performance API Gateway in DB-less mode.
https://github.com/calpa/kong-zeabur
api-gateway containers db-less kong kong-gateway kubernetes microservices serverless zeabur
Last synced: about 1 month ago
JSON representation
π Kong Gateway DB-less template for Zeabur. One-click deployment of a lightweight, high-performance API Gateway in DB-less mode.
- Host: GitHub
- URL: https://github.com/calpa/kong-zeabur
- Owner: calpa
- License: mit
- Created: 2025-05-19T03:40:57.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2025-05-19T03:54:02.000Z (5 months ago)
- Last Synced: 2025-05-19T04:32:07.273Z (5 months ago)
- Topics: api-gateway, containers, db-less, kong, kong-gateway, kubernetes, microservices, serverless, zeabur
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# π Kong Gateway OSS (DB-less Mode) on Zeabur
[](https://zeabur.com/templates/QUF7QG)

[ηΉι«δΈζ README](README.zh-TW.md)
## β¨ Features
- π **One-Click Deployment** on Zeabur
- ποΈ **Database-less** - Runs entirely in-memory
- π **Declarative Configuration** - Define routes and plugins as code
- π **Pre-configured** with a sample httpbin service
- π **Custom Domain** support
- π **Kong Manager** included
- π **Stateless** - Perfect for serverless and containerized environments## π Deployment
### Option 1: One-Click Deployment (Recommended)
[](https://zeabur.com/templates/QUF7QG)
1. Click the "Deploy on Zeabur" button above
2. Set your preferred domain name
3. Deploy! π### Option 2: Using Zeabur CLI
```bash
# Install Zeabur CLI if you haven't
npm install -g @zeabur/cli# Deploy the template
zeabur template deploy kong-db-less.yml# Or update an existing template
zeabur template update -c QUF7QG -f kong-db-less.yml
```## βοΈ Configuration
### Environment Variables
| Variable | Description | Default |
|----------|-------------|---------|
| `KONG_DATABASE` | Database mode (always `off` for DB-less) | `off` |
| `KONG_DECLARATIVE_CONFIG` | Path to declarative config | `/kong/declarative/kong.yml` |
| `KONG_ADMIN_LISTEN` | Admin API listen address | `0.0.0.0:8001` |
| `KONG_PROXY_ACCESS_LOG` | Proxy access log location | `/dev/stdout` |
| `KONG_NGINX_WORKER_PROCESSES` | Number of worker processes | `1` |### Custom Configuration
Edit the `kong.yml` file in the `volumes` section to customize your Kong Gateway configuration. The configuration is written in declarative YAML format.
## π‘ Usage
### Accessing Services
- **Kong Proxy**: `https://your-domain.zeabur.app`
- Sample route: `https://your-domain.zeabur.app/httpbin`
- **Kong Manager UI**: `https://your-domain.zeabur.app:8002`
- **Status Endpoint**: `https://your-domain.zeabur.app/status`### Default Routes
- `/httpbin` - Proxies to httpbin.org (example service)
- `/status` - Health check endpoint## π§ Development
### Updating the Template
1. Make your changes to `kong-db-less.yml`
2. Update the template on Zeabur:
```bash
npx zeabur template update -c QUF7QG -f kong-db-less.yml
```### Testing Locally
1. Install [Docker](https://www.docker.com/)
2. Run Kong Gateway locally:
```bash
docker run -d --name kong \
-e "KONG_DATABASE=off" \
-e "KONG_DECLARATIVE_CONFIG=/kong.yml" \
-v $(pwd)/kong.yml:/kong.yml \
-p 8000:8000 \
-p 8001:8001 \
kong/kong-gateway:3.10.0.1
```## π Security
- π Admin API (port 8001) is not exposed to the internet
- π Consider adding authentication for production use
- π Regularly update to the latest Kong Gateway version
- π Review and customize the default CORS and rate limiting settings## π License
This project is licensed under the [MIT License](LICENSE).
---