Skip to content

Commit 7dfd2fb

Browse files
committed
feat: add 9Router template (#1040)
1 parent 285e667 commit 7dfd2fb

4 files changed

Lines changed: 69 additions & 0 deletions

File tree

blueprints/9router/9router.png

105 KB
Loading
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
version: "3.8"
2+
3+
services:
4+
9router:
5+
image: decolua/9router:0.5.40
6+
restart: unless-stopped
7+
environment:
8+
DATA_DIR: /app/data
9+
PORT: "20128"
10+
HOSTNAME: "0.0.0.0"
11+
NODE_ENV: production
12+
JWT_SECRET: ${JWT_SECRET}
13+
INITIAL_PASSWORD: ${INITIAL_PASSWORD}
14+
API_KEY_SECRET: ${API_KEY_SECRET}
15+
MACHINE_ID_SALT: ${MACHINE_ID_SALT}
16+
BASE_URL: https://${ROUTER_HOST}
17+
HEADROOM_URL: http://headroom:8787
18+
AUTH_COOKIE_SECURE: "true"
19+
volumes:
20+
- 9router-data:/app/data
21+
depends_on:
22+
- headroom
23+
24+
# Optional token-reduction proxy that 9Router calls through HEADROOM_URL.
25+
# Shipped as a sidecar because the 9Router image does not bundle it.
26+
headroom:
27+
image: ghcr.io/chopratejas/headroom:latest
28+
restart: unless-stopped
29+
30+
volumes:
31+
9router-data:

blueprints/9router/meta.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"id": "9router",
3+
"name": "9Router",
4+
"version": "0.5.40",
5+
"description": "Self-hosted AI model router that rotates requests across 40+ providers with automatic fallback, exposing an OpenAI-compatible endpoint for coding agents.",
6+
"logo": "9router.png",
7+
"links": {
8+
"github": "https://github.com/decolua/9router",
9+
"website": "https://9router.com",
10+
"docs": "https://github.com/decolua/9router/blob/master/DOCKER.md"
11+
},
12+
"tags": [
13+
"ai",
14+
"proxy",
15+
"developer-tools"
16+
]
17+
}

blueprints/9router/template.toml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
[variables]
2+
main_domain = "${domain}"
3+
jwt_secret = "${password:64}"
4+
initial_password = "${password:32}"
5+
api_key_secret = "${password:64}"
6+
machine_id_salt = "${password:32}"
7+
8+
[config]
9+
env = [
10+
"ROUTER_HOST=${main_domain}",
11+
"JWT_SECRET=${jwt_secret}",
12+
"INITIAL_PASSWORD=${initial_password}",
13+
"API_KEY_SECRET=${api_key_secret}",
14+
"MACHINE_ID_SALT=${machine_id_salt}",
15+
]
16+
mounts = []
17+
18+
[[config.domains]]
19+
serviceName = "9router"
20+
port = 20128
21+
host = "${main_domain}"

0 commit comments

Comments
 (0)