Merge remote-tracking branch 'origin/master' into feat/hwlab-1119-d601-external-db
# Conflicts: # config/platform-db/postgres-pk01.yaml # scripts/src/platform-db.ts
This commit is contained in:
@@ -9,6 +9,8 @@ metadata:
|
||||
- 280
|
||||
- 281
|
||||
- 1119
|
||||
- 297
|
||||
- 300
|
||||
|
||||
cluster:
|
||||
role: primary
|
||||
@@ -86,6 +88,9 @@ postgres:
|
||||
- id: D601-public
|
||||
cidr: 36.49.29.73/32
|
||||
purpose: platform-infra-and-hwlab-v03-app
|
||||
- id: G14-public
|
||||
cidr: 202.98.17.68/32
|
||||
purpose: platform-infra-runtime
|
||||
tuning:
|
||||
maxConnections: 50
|
||||
sharedBuffers: 512MB
|
||||
@@ -141,6 +146,66 @@ postgres:
|
||||
user: hwlab_d601_v03_app
|
||||
address: 36.49.29.73/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: langbot
|
||||
user: langbot
|
||||
address: 10.0.8.0/22
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: postgres
|
||||
user: langbot
|
||||
address: 10.0.8.0/22
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: langbot
|
||||
user: langbot
|
||||
address: 74.48.78.17/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: postgres
|
||||
user: langbot
|
||||
address: 74.48.78.17/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: langbot
|
||||
user: langbot
|
||||
address: 202.98.17.68/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: postgres
|
||||
user: langbot
|
||||
address: 202.98.17.68/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: n8n
|
||||
user: n8n
|
||||
address: 10.0.8.0/22
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: postgres
|
||||
user: n8n
|
||||
address: 10.0.8.0/22
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: n8n
|
||||
user: n8n
|
||||
address: 74.48.78.17/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: postgres
|
||||
user: n8n
|
||||
address: 74.48.78.17/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: n8n
|
||||
user: n8n
|
||||
address: 202.98.17.68/32
|
||||
method: scram-sha-256
|
||||
- type: hostssl
|
||||
database: postgres
|
||||
user: n8n
|
||||
address: 202.98.17.68/32
|
||||
method: scram-sha-256
|
||||
|
||||
secrets:
|
||||
source: master-local
|
||||
@@ -174,6 +239,34 @@ secrets:
|
||||
HWLAB_D601_V03_DB_NAME: hwlab_d601_v03
|
||||
randomHex:
|
||||
HWLAB_D601_V03_DB_PASSWORD: 32
|
||||
- name: langbot-db-credentials
|
||||
sourceRef: platform-db/langbot-db.env
|
||||
type: env
|
||||
requiredKeys:
|
||||
- LANGBOT_DB_USER
|
||||
- LANGBOT_DB_PASSWORD
|
||||
- LANGBOT_DB_NAME
|
||||
createIfMissing:
|
||||
enabled: true
|
||||
values:
|
||||
LANGBOT_DB_USER: langbot
|
||||
LANGBOT_DB_NAME: langbot
|
||||
randomHex:
|
||||
LANGBOT_DB_PASSWORD: 32
|
||||
- name: n8n-db-credentials
|
||||
sourceRef: platform-db/n8n-db.env
|
||||
type: env
|
||||
requiredKeys:
|
||||
- N8N_DB_USER
|
||||
- N8N_DB_PASSWORD
|
||||
- N8N_DB_NAME
|
||||
createIfMissing:
|
||||
enabled: true
|
||||
values:
|
||||
N8N_DB_USER: n8n
|
||||
N8N_DB_NAME: n8n
|
||||
randomHex:
|
||||
N8N_DB_PASSWORD: 32
|
||||
|
||||
objects:
|
||||
roles:
|
||||
@@ -195,6 +288,24 @@ objects:
|
||||
createdb: false
|
||||
createrole: false
|
||||
superuser: false
|
||||
- name: langbot
|
||||
passwordRef:
|
||||
sourceRef: platform-db/langbot-db.env
|
||||
key: LANGBOT_DB_PASSWORD
|
||||
login: true
|
||||
attributes:
|
||||
createdb: false
|
||||
createrole: false
|
||||
superuser: false
|
||||
- name: n8n
|
||||
passwordRef:
|
||||
sourceRef: platform-db/n8n-db.env
|
||||
key: N8N_DB_PASSWORD
|
||||
login: true
|
||||
attributes:
|
||||
createdb: false
|
||||
createrole: false
|
||||
superuser: false
|
||||
databases:
|
||||
- name: sub2api
|
||||
owner: sub2api
|
||||
@@ -206,6 +317,16 @@ objects:
|
||||
encoding: UTF8
|
||||
locale: C.UTF-8
|
||||
extensions: []
|
||||
- name: langbot
|
||||
owner: langbot
|
||||
encoding: UTF8
|
||||
locale: C.UTF-8
|
||||
extensions: []
|
||||
- name: n8n
|
||||
owner: n8n
|
||||
encoding: UTF8
|
||||
locale: C.UTF-8
|
||||
extensions: []
|
||||
|
||||
exports:
|
||||
connectionStrings:
|
||||
@@ -254,6 +375,36 @@ exports:
|
||||
- scope: hwlab-v03
|
||||
secret: hwlab-v03-openfga
|
||||
key: datastore-uri
|
||||
- name: langbot-database-url
|
||||
sourceSecretRef: platform-db/langbot-db.env
|
||||
render:
|
||||
envKey: DATABASE_URL
|
||||
format: postgresql://$(LANGBOT_DB_USER):$(LANGBOT_DB_PASSWORD)@$(PGHOST):5432/$(LANGBOT_DB_NAME)?sslmode=require
|
||||
variables:
|
||||
PGHOST: 82.156.23.220
|
||||
writeToSecretSource:
|
||||
sourceRef: platform-infra/langbot.env
|
||||
key: DATABASE_URL
|
||||
mode: update-or-insert
|
||||
consumers:
|
||||
- scope: platform-infra
|
||||
secret: langbot-secrets
|
||||
key: DATABASE_URL
|
||||
- name: n8n-database-url
|
||||
sourceSecretRef: platform-db/n8n-db.env
|
||||
render:
|
||||
envKey: DATABASE_URL
|
||||
format: postgresql://$(N8N_DB_USER):$(N8N_DB_PASSWORD)@$(PGHOST):5432/$(N8N_DB_NAME)?sslmode=require
|
||||
variables:
|
||||
PGHOST: 82.156.23.220
|
||||
writeToSecretSource:
|
||||
sourceRef: platform-infra/n8n.env
|
||||
key: DATABASE_URL
|
||||
mode: update-or-insert
|
||||
consumers:
|
||||
- scope: platform-infra
|
||||
secret: n8n-secrets
|
||||
key: DATABASE_URL
|
||||
|
||||
backup:
|
||||
phase: minimum-restoreable
|
||||
@@ -284,6 +435,15 @@ observability:
|
||||
- kind: psql-app-role
|
||||
database: sub2api
|
||||
user: sub2api
|
||||
- kind: psql-app-role
|
||||
database: hwlab_d601_v03
|
||||
user: hwlab_d601_v03_app
|
||||
- kind: psql-app-role
|
||||
database: langbot
|
||||
user: langbot
|
||||
- kind: psql-app-role
|
||||
database: n8n
|
||||
user: n8n
|
||||
- kind: disk-free
|
||||
path: /var/lib/postgresql/16/main
|
||||
minFreeGiB: 10
|
||||
|
||||
@@ -0,0 +1,98 @@
|
||||
version: 1
|
||||
kind: platform-infra-langbot
|
||||
|
||||
metadata:
|
||||
id: langbot-public
|
||||
owner: unidesk
|
||||
relatedIssues:
|
||||
- 297
|
||||
|
||||
image:
|
||||
repository: rockchin/langbot
|
||||
tag: v4.10.1
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
dependencyImages:
|
||||
postgresClient: docker.io/library/postgres:16-alpine
|
||||
|
||||
targets:
|
||||
- id: G14
|
||||
route: G14:k3s
|
||||
namespace: platform-infra
|
||||
enabled: true
|
||||
replicas: 1
|
||||
publicExposure:
|
||||
enabled: true
|
||||
publicBaseUrl: https://langbot.pikapython.com
|
||||
dns:
|
||||
hostname: langbot.pikapython.com
|
||||
expectedA: 82.156.23.220
|
||||
resolvers: [1.1.1.1, 8.8.8.8, 223.5.5.5, 114.114.114.114]
|
||||
frpc:
|
||||
deploymentName: langbot-frpc
|
||||
secretName: langbot-frpc-secrets
|
||||
secretKey: frpc.toml
|
||||
image: fatedier/frpc:v0.68.1
|
||||
serverAddr: 82.156.23.220
|
||||
serverPort: 22000
|
||||
proxyName: platform-infra-langbot-g14-web
|
||||
remotePort: 22097
|
||||
localIP: langbot.platform-infra.svc.cluster.local
|
||||
localPort: 5300
|
||||
tokenSourceRef: platform-infra/pk01-frp.env
|
||||
tokenSourceKey: FRP_TOKEN
|
||||
pk01:
|
||||
route: PK01
|
||||
caddyConfigPath: /etc/caddy/Caddyfile
|
||||
caddyServiceName: caddy
|
||||
responseHeaderTimeoutSeconds: 600
|
||||
|
||||
runtime:
|
||||
timezone: Asia/Shanghai
|
||||
database:
|
||||
mode: external
|
||||
sourceRef: platform-db/langbot-db.env
|
||||
sourceKeys:
|
||||
user: LANGBOT_DB_USER
|
||||
password: LANGBOT_DB_PASSWORD
|
||||
dbName: LANGBOT_DB_NAME
|
||||
secretName: langbot-secrets
|
||||
host: 82.156.23.220
|
||||
port: 5432
|
||||
user: langbot
|
||||
dbName: langbot
|
||||
sslMode: require
|
||||
appDatabaseValue: langbot?ssl=require
|
||||
secrets:
|
||||
root: /root/unidesk/.state/secrets
|
||||
appSourceRef: platform-infra/langbot.env
|
||||
storage:
|
||||
data:
|
||||
name: langbot-data
|
||||
size: 10Gi
|
||||
plugins:
|
||||
name: langbot-plugins
|
||||
size: 5Gi
|
||||
pluginRuntime:
|
||||
name: langbot-plugin-runtime-data
|
||||
size: 5Gi
|
||||
box:
|
||||
enabled: false
|
||||
reason: LangBot Box mounts Docker socket in the official manifest; public platform service keeps it disabled by default.
|
||||
|
||||
apiKey:
|
||||
sourceRef: platform-infra/langbot.env
|
||||
key: LANGBOT_API_KEY
|
||||
name: unidesk-langbot-cli
|
||||
description: UniDesk controlled CLI API key for langbot.pikapython.com
|
||||
|
||||
officialWechat:
|
||||
supportedAdapters:
|
||||
- officialaccount
|
||||
- wecom
|
||||
- wecomcs
|
||||
webhookBaseUrl: https://langbot.pikapython.com
|
||||
defaultCallbackPath: /callback/command
|
||||
notes:
|
||||
- Official account, WeCom, and WeCom customer service adapters are supported through LangBot official platform sources.
|
||||
- Personal WeChat/OpenClaw is not enabled by default for this public service.
|
||||
@@ -0,0 +1,83 @@
|
||||
version: 1
|
||||
kind: platform-infra-n8n
|
||||
|
||||
metadata:
|
||||
id: n8n-public
|
||||
owner: unidesk
|
||||
relatedIssues:
|
||||
- 300
|
||||
|
||||
image:
|
||||
repository: n8nio/n8n
|
||||
tag: "1.123.55"
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
dependencyImages:
|
||||
postgresClient: docker.io/library/postgres:16-alpine
|
||||
|
||||
targets:
|
||||
- id: G14
|
||||
route: G14:k3s
|
||||
namespace: platform-infra
|
||||
enabled: true
|
||||
replicas: 1
|
||||
publicExposure:
|
||||
enabled: true
|
||||
publicBaseUrl: https://n8n.pikapython.com
|
||||
dns:
|
||||
hostname: n8n.pikapython.com
|
||||
expectedA: 82.156.23.220
|
||||
resolvers: [1.1.1.1, 8.8.8.8, 223.5.5.5, 114.114.114.114]
|
||||
frpc:
|
||||
deploymentName: n8n-frpc
|
||||
secretName: n8n-frpc-secrets
|
||||
secretKey: frpc.toml
|
||||
image: fatedier/frpc:v0.68.1
|
||||
serverAddr: 82.156.23.220
|
||||
serverPort: 22000
|
||||
proxyName: platform-infra-n8n-g14-web
|
||||
remotePort: 22099
|
||||
localIP: n8n.platform-infra.svc.cluster.local
|
||||
localPort: 5678
|
||||
tokenSourceRef: platform-infra/pk01-frp.env
|
||||
tokenSourceKey: FRP_TOKEN
|
||||
pk01:
|
||||
route: PK01
|
||||
caddyConfigPath: /etc/caddy/Caddyfile
|
||||
caddyServiceName: caddy
|
||||
responseHeaderTimeoutSeconds: 600
|
||||
|
||||
runtime:
|
||||
timezone: Asia/Shanghai
|
||||
database:
|
||||
mode: external
|
||||
sourceRef: platform-db/n8n-db.env
|
||||
sourceKeys:
|
||||
user: N8N_DB_USER
|
||||
password: N8N_DB_PASSWORD
|
||||
dbName: N8N_DB_NAME
|
||||
secretName: n8n-secrets
|
||||
host: 82.156.23.220
|
||||
port: 5432
|
||||
user: n8n
|
||||
dbName: n8n
|
||||
sslMode: require
|
||||
sslRejectUnauthorized: false
|
||||
secrets:
|
||||
root: /root/unidesk/.state/secrets
|
||||
appSourceRef: platform-infra/n8n.env
|
||||
encryptionKey: N8N_ENCRYPTION_KEY
|
||||
storage:
|
||||
data:
|
||||
name: n8n-data
|
||||
size: 10Gi
|
||||
public:
|
||||
host: n8n.pikapython.com
|
||||
protocol: https
|
||||
editorBaseUrl: https://n8n.pikapython.com
|
||||
webhookUrl: https://n8n.pikapython.com
|
||||
proxyHops: 1
|
||||
security:
|
||||
diagnosticsEnabled: false
|
||||
personalisationEnabled: false
|
||||
secureCookie: true
|
||||
@@ -152,6 +152,8 @@ localCodex:
|
||||
backupSuffix: pre-sub2api
|
||||
providerName: OpenAI
|
||||
wireApi: responses
|
||||
modelContextWindow: 272000
|
||||
modelAutoCompactTokenLimit: 240000
|
||||
supportsWebSockets: false
|
||||
responsesWebSocketsV2: false
|
||||
responsesSmokeModel: gpt-5.5
|
||||
@@ -159,7 +161,7 @@ sentinel:
|
||||
monitor:
|
||||
enabled: true
|
||||
actions:
|
||||
enabled: true
|
||||
enabled: false
|
||||
schedule: "*/1 * * * *"
|
||||
image: python:3.12-alpine
|
||||
sdk:
|
||||
|
||||
Reference in New Issue
Block a user