404 lines
18 KiB
YAML
404 lines
18 KiB
YAML
{
|
|
"apiVersion": "v1",
|
|
"kind": "List",
|
|
"items": [
|
|
{
|
|
"apiVersion": "v1",
|
|
"kind": "ConfigMap",
|
|
"metadata": {
|
|
"name": "hwlab-deepseek-proxy-config",
|
|
"namespace": "hwlab-v03",
|
|
"labels": {
|
|
"app.kubernetes.io/name": "hwlab-deepseek-proxy",
|
|
"app.kubernetes.io/part-of": "hwlab",
|
|
"hwlab.pikastech.local/environment": "v03",
|
|
"hwlab.pikastech.local/gitops-target": "v03",
|
|
"hwlab.pikastech.local/service-id": "hwlab-deepseek-proxy",
|
|
"hwlab.pikastech.local/source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/monitoring": "enabled"
|
|
}
|
|
},
|
|
"data": {
|
|
"render-config.sh": "#!/bin/sh\nif [ -z \"${DEEPSEEK_API_KEY:-}\" ] && [ -z \"${OPENCODE_API_KEY:-}\" ]; then\n echo \"at least one of DEEPSEEK_API_KEY or OPENCODE_API_KEY is required\" >&2\n exit 1\nfi\ncat > /config/config.yml <<EOF\nmode: \"Transform\"\nlog:\n level: \"info\"\n format: \"text\"\nserver:\n addr: \"0.0.0.0:4001\"\npersistence:\n active_provider: db_sqlite\nextensions:\n db_sqlite:\n enabled: true\n config:\n path: /data/moonbridge.db\n wal: true\n busy_timeout_ms: 5000\n max_open_conns: 1\n metrics:\n enabled: true\n config:\n default_limit: 100\n max_limit: 1000\n deepseek_v4:\n config:\n reinforce_instructions: true\n reinforce_prompt: \"[System Reminder]: Please pay close attention to the system instructions, AGENTS.md files, and any other context provided. Follow them carefully and completely in your response.\\n[User]:\"\ncache:\n mode: \"explicit\"\n ttl: \"5m\"\n prompt_caching: true\n automatic_prompt_cache: false\n explicit_cache_breakpoints: true\n allow_retention_downgrade: false\n max_breakpoints: 4\n min_cache_tokens: 1024\n expected_reuse: 2\n minimum_value_score: 2048\n min_breakpoint_tokens: 1024\ndefaults:\n model: \"deepseek-chat\"\n max_tokens: 8192\ntrace:\n enabled: false\nmodels:\n deepseek-chat:\n context_window: 128000\n max_output_tokens: 8192\n display_name: \"deepseek-chat\"\n description: \"DeepSeek via Moon Bridge\"\n default_reasoning_level: null\n supported_reasoning_levels: []\n extensions:\n deepseek_v4:\n enabled: true\n deepseek-v4-flash:\n context_window: 1000000\n max_output_tokens: 384000\n display_name: \"DeepSeek V4 Flash via OpenCode Zen Go\"\n description: \"DeepSeek V4 Flash through OpenCode Zen Go Chat Completions via Moon Bridge\"\n default_reasoning_level: \"xhigh\"\n supported_reasoning_levels:\n - effort: \"high\"\n description: \"High reasoning effort\"\n - effort: \"xhigh\"\n description: \"Maximum reasoning effort\"\n supports_reasoning_summaries: true\n default_reasoning_summary: \"auto\"\n extensions:\n deepseek_v4:\n enabled: true\nproviders:\n deepseek:\n base_url: \"https://api.deepseek.com/anthropic\"\n api_key: \"${DEEPSEEK_API_KEY}\"\n version: \"2023-06-01\"\n user_agent: \"moonbridge/1.0\"\n offers:\n - model: deepseek-chat\n opencode:\n base_url: \"https://opencode.ai/zen/go/v1\"\n api_key: \"${OPENCODE_API_KEY:-}\"\n protocol: \"openai-chat\"\n user_agent: \"moonbridge-dsflash-go/1.0\"\n web_search:\n support: \"disabled\"\n offers:\n - model: deepseek-v4-flash\nroutes:\n deepseek-chat:\n model: deepseek-chat\n provider: deepseek\n deepseek-v4-flash:\n model: deepseek-v4-flash\n provider: opencode\nEOF\n"
|
|
}
|
|
},
|
|
{
|
|
"apiVersion": "apps/v1",
|
|
"kind": "Deployment",
|
|
"metadata": {
|
|
"name": "hwlab-deepseek-proxy",
|
|
"namespace": "hwlab-v03",
|
|
"labels": {
|
|
"app.kubernetes.io/name": "hwlab-deepseek-proxy",
|
|
"app.kubernetes.io/part-of": "hwlab",
|
|
"hwlab.pikastech.local/environment": "v03",
|
|
"hwlab.pikastech.local/gitops-target": "v03",
|
|
"hwlab.pikastech.local/service-id": "hwlab-deepseek-proxy",
|
|
"hwlab.pikastech.local/source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/monitoring": "enabled"
|
|
},
|
|
"annotations": {
|
|
"hwlab.pikastech.local/moonbridge-source-ref": "1b99888d3dae889b79ee602cb875c7907f7e76f2",
|
|
"hwlab.pikastech.local/bridge-service-id": "hwlab-cloud-api",
|
|
"hwlab.pikastech.local/source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-image-tag": "env-cc508eb657a4",
|
|
"hwlab.pikastech.local/bridge-image": "127.0.0.1:5000/hwlab/hwlab-cloud-api-env@sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36",
|
|
"hwlab.pikastech.local/metrics-sidecar-sha256": "782e26256b5a5cddff52a165a0eb5f852973eee1aac1b19acac4a313db7968f4",
|
|
"hwlab.pikastech.local/bridge-runtime-mode": "env-reuse-git-mirror-checkout",
|
|
"hwlab.pikastech.local/bridge-boot-repo": "git@github.com:pikasTech/HWLAB.git",
|
|
"hwlab.pikastech.local/bridge-boot-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-boot-sh": "deploy/runtime/boot/hwlab-deepseek-responses-bridge.sh",
|
|
"hwlab.pikastech.local/bridge-environment-digest": "sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36"
|
|
}
|
|
},
|
|
"spec": {
|
|
"replicas": 1,
|
|
"selector": {
|
|
"matchLabels": {
|
|
"app.kubernetes.io/name": "hwlab-deepseek-proxy"
|
|
}
|
|
},
|
|
"template": {
|
|
"metadata": {
|
|
"labels": {
|
|
"app.kubernetes.io/name": "hwlab-deepseek-proxy",
|
|
"app.kubernetes.io/part-of": "hwlab",
|
|
"hwlab.pikastech.local/environment": "v03",
|
|
"hwlab.pikastech.local/gitops-target": "v03",
|
|
"hwlab.pikastech.local/service-id": "hwlab-deepseek-proxy",
|
|
"hwlab.pikastech.local/source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/monitoring": "enabled",
|
|
"hwlab.pikastech.local/bridge-source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-runtime-mode": "env-reuse-git-mirror-checkout",
|
|
"hwlab.pikastech.local/bridge-boot-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126"
|
|
},
|
|
"annotations": {
|
|
"hwlab.pikastech.local/bridge-service-id": "hwlab-cloud-api",
|
|
"hwlab.pikastech.local/source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-image-tag": "env-cc508eb657a4",
|
|
"hwlab.pikastech.local/bridge-image": "127.0.0.1:5000/hwlab/hwlab-cloud-api-env@sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36",
|
|
"hwlab.pikastech.local/metrics-sidecar-sha256": "782e26256b5a5cddff52a165a0eb5f852973eee1aac1b19acac4a313db7968f4",
|
|
"hwlab.pikastech.local/bridge-runtime-mode": "env-reuse-git-mirror-checkout",
|
|
"hwlab.pikastech.local/bridge-boot-repo": "git@github.com:pikasTech/HWLAB.git",
|
|
"hwlab.pikastech.local/bridge-boot-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/bridge-boot-sh": "deploy/runtime/boot/hwlab-deepseek-responses-bridge.sh",
|
|
"hwlab.pikastech.local/bridge-environment-digest": "sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36"
|
|
}
|
|
},
|
|
"spec": {
|
|
"initContainers": [
|
|
{
|
|
"name": "moonbridge-config",
|
|
"image": "127.0.0.1:5000/hwlab/hwlab-cloud-api-env@sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36",
|
|
"imagePullPolicy": "IfNotPresent",
|
|
"command": [
|
|
"/bin/sh",
|
|
"-eu",
|
|
"/scripts/render-config.sh"
|
|
],
|
|
"env": [
|
|
{
|
|
"name": "DEEPSEEK_API_KEY",
|
|
"valueFrom": {
|
|
"secretKeyRef": {
|
|
"name": "hwlab-v03-code-agent-provider",
|
|
"key": "openai-api-key",
|
|
"optional": true
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"name": "OPENCODE_API_KEY",
|
|
"valueFrom": {
|
|
"secretKeyRef": {
|
|
"name": "hwlab-v03-code-agent-provider",
|
|
"key": "opencode-api-key",
|
|
"optional": true
|
|
}
|
|
}
|
|
}
|
|
],
|
|
"volumeMounts": [
|
|
{
|
|
"name": "moonbridge-scripts",
|
|
"mountPath": "/scripts",
|
|
"readOnly": true
|
|
},
|
|
{
|
|
"name": "moonbridge-config",
|
|
"mountPath": "/config"
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"containers": [
|
|
{
|
|
"name": "responses-bridge",
|
|
"image": "127.0.0.1:5000/hwlab/hwlab-cloud-api-env@sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36",
|
|
"imagePullPolicy": "IfNotPresent",
|
|
"env": [
|
|
{
|
|
"name": "PORT",
|
|
"value": "4000"
|
|
},
|
|
{
|
|
"name": "HWLAB_COMMIT_ID",
|
|
"value": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126"
|
|
},
|
|
{
|
|
"name": "HWLAB_IMAGE",
|
|
"value": "127.0.0.1:5000/hwlab/hwlab-cloud-api-env@sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36"
|
|
},
|
|
{
|
|
"name": "HWLAB_IMAGE_TAG",
|
|
"value": "env-cc508eb657a4"
|
|
},
|
|
{
|
|
"name": "HWLAB_DEEPSEEK_BRIDGE_UPSTREAM",
|
|
"value": "http://127.0.0.1:4001"
|
|
},
|
|
{
|
|
"name": "HWLAB_DEEPSEEK_BRIDGE_MODEL",
|
|
"value": "deepseek-chat"
|
|
},
|
|
{
|
|
"name": "HWLAB_RUNTIME_MODE",
|
|
"value": "env-reuse-git-mirror-checkout"
|
|
},
|
|
{
|
|
"name": "HWLAB_BOOT_REPO",
|
|
"value": "git@github.com:pikasTech/HWLAB.git"
|
|
},
|
|
{
|
|
"name": "HWLAB_BOOT_COMMIT",
|
|
"value": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126"
|
|
},
|
|
{
|
|
"name": "HWLAB_BOOT_REF",
|
|
"value": "v0.3"
|
|
},
|
|
{
|
|
"name": "HWLAB_BOOT_SH",
|
|
"value": "deploy/runtime/boot/hwlab-deepseek-responses-bridge.sh"
|
|
},
|
|
{
|
|
"name": "HWLAB_BOOT_READ_URL",
|
|
"value": "http://git-mirror-http.devops-infra.svc.cluster.local/pikasTech/HWLAB.git"
|
|
},
|
|
{
|
|
"name": "HWLAB_ENVIRONMENT_IMAGE",
|
|
"value": "127.0.0.1:5000/hwlab/hwlab-cloud-api-env:env-cc508eb657a4"
|
|
},
|
|
{
|
|
"name": "HWLAB_ENVIRONMENT_DIGEST",
|
|
"value": "sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36"
|
|
},
|
|
{
|
|
"name": "HWLAB_ENVIRONMENT_INPUT_HASH",
|
|
"value": "cc508eb657a455c738b9f2477b1d669af6163fa4863b400e371716b9f3ee39af"
|
|
},
|
|
{
|
|
"name": "HWLAB_CODE_INPUT_HASH",
|
|
"value": "e2d48031bdb318a3bf175c7eb33c62963c94aaebe20d15445b3a4690bfb2530e"
|
|
},
|
|
{
|
|
"name": "HWLAB_IMAGE_DIGEST",
|
|
"value": "sha256:36005f0676a3aa36b27d20b931a515072a7448a42d39f0160faea1c2a82ddc36"
|
|
}
|
|
],
|
|
"ports": [
|
|
{
|
|
"name": "http",
|
|
"containerPort": 4000
|
|
}
|
|
],
|
|
"readinessProbe": {
|
|
"httpGet": {
|
|
"path": "/health/readiness",
|
|
"port": "http"
|
|
},
|
|
"initialDelaySeconds": 10,
|
|
"periodSeconds": 10
|
|
},
|
|
"livenessProbe": {
|
|
"httpGet": {
|
|
"path": "/health/liveliness",
|
|
"port": "http"
|
|
},
|
|
"initialDelaySeconds": 20,
|
|
"periodSeconds": 20
|
|
}
|
|
},
|
|
{
|
|
"name": "moonbridge",
|
|
"image": "127.0.0.1:5000/hwlab/moonbridge:1b99888d3dae",
|
|
"imagePullPolicy": "IfNotPresent",
|
|
"args": [
|
|
"-config",
|
|
"/config/config.yml"
|
|
],
|
|
"ports": [
|
|
{
|
|
"name": "moonbridge-http",
|
|
"containerPort": 4001
|
|
}
|
|
],
|
|
"readinessProbe": {
|
|
"httpGet": {
|
|
"path": "/v1/models",
|
|
"port": "moonbridge-http"
|
|
},
|
|
"initialDelaySeconds": 10,
|
|
"periodSeconds": 10
|
|
},
|
|
"livenessProbe": {
|
|
"httpGet": {
|
|
"path": "/v1/models",
|
|
"port": "moonbridge-http"
|
|
},
|
|
"initialDelaySeconds": 20,
|
|
"periodSeconds": 20
|
|
},
|
|
"volumeMounts": [
|
|
{
|
|
"name": "moonbridge-config",
|
|
"mountPath": "/config",
|
|
"readOnly": true
|
|
},
|
|
{
|
|
"name": "moonbridge-data",
|
|
"mountPath": "/data"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "hwlab-metrics",
|
|
"image": "127.0.0.1:5000/hwlab/hwlab-ci-node-tools:node22-alpine-bun-v1",
|
|
"imagePullPolicy": "IfNotPresent",
|
|
"command": [
|
|
"node",
|
|
"/metrics/metrics-sidecar.mjs"
|
|
],
|
|
"env": [
|
|
{
|
|
"name": "HWLAB_METRICS_SERVICE_ID",
|
|
"value": "hwlab-deepseek-proxy"
|
|
},
|
|
{
|
|
"name": "HWLAB_METRICS_NAMESPACE",
|
|
"value": "hwlab-v03"
|
|
},
|
|
{
|
|
"name": "HWLAB_METRICS_GITOPS_TARGET",
|
|
"value": "v03"
|
|
},
|
|
{
|
|
"name": "HWLAB_METRICS_PORT",
|
|
"value": "9100"
|
|
},
|
|
{
|
|
"name": "HWLAB_METRICS_TARGET_URL",
|
|
"value": "http://127.0.0.1:4000/health/live"
|
|
},
|
|
{
|
|
"name": "HWLAB_METRICS_TARGET_TIMEOUT_MS",
|
|
"value": "2000"
|
|
}
|
|
],
|
|
"ports": [
|
|
{
|
|
"name": "metrics",
|
|
"containerPort": 9100
|
|
}
|
|
],
|
|
"readinessProbe": {
|
|
"httpGet": {
|
|
"path": "/health/live",
|
|
"port": "metrics"
|
|
},
|
|
"initialDelaySeconds": 3,
|
|
"periodSeconds": 10
|
|
},
|
|
"livenessProbe": {
|
|
"httpGet": {
|
|
"path": "/health/live",
|
|
"port": "metrics"
|
|
},
|
|
"initialDelaySeconds": 10,
|
|
"periodSeconds": 20
|
|
},
|
|
"volumeMounts": [
|
|
{
|
|
"name": "hwlab-metrics-sidecar",
|
|
"mountPath": "/metrics",
|
|
"readOnly": true
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"volumes": [
|
|
{
|
|
"name": "moonbridge-scripts",
|
|
"configMap": {
|
|
"name": "hwlab-deepseek-proxy-config"
|
|
}
|
|
},
|
|
{
|
|
"name": "moonbridge-config",
|
|
"emptyDir": {}
|
|
},
|
|
{
|
|
"name": "moonbridge-data",
|
|
"emptyDir": {}
|
|
},
|
|
{
|
|
"name": "hwlab-metrics-sidecar",
|
|
"configMap": {
|
|
"name": "hwlab-v03-metrics-sidecar"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"apiVersion": "v1",
|
|
"kind": "Service",
|
|
"metadata": {
|
|
"name": "hwlab-deepseek-proxy",
|
|
"namespace": "hwlab-v03",
|
|
"labels": {
|
|
"app.kubernetes.io/name": "hwlab-deepseek-proxy",
|
|
"app.kubernetes.io/part-of": "hwlab",
|
|
"hwlab.pikastech.local/environment": "v03",
|
|
"hwlab.pikastech.local/gitops-target": "v03",
|
|
"hwlab.pikastech.local/service-id": "hwlab-deepseek-proxy",
|
|
"hwlab.pikastech.local/source-commit": "f3a8615bd5af9b20ae6b0aa7c83b5f6a2942c126",
|
|
"hwlab.pikastech.local/monitoring": "enabled"
|
|
}
|
|
},
|
|
"spec": {
|
|
"type": "ClusterIP",
|
|
"selector": {
|
|
"app.kubernetes.io/name": "hwlab-deepseek-proxy"
|
|
},
|
|
"ports": [
|
|
{
|
|
"name": "http",
|
|
"port": 4000,
|
|
"targetPort": "http"
|
|
},
|
|
{
|
|
"name": "metrics",
|
|
"port": 9100,
|
|
"targetPort": "metrics"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
}
|