feat: 无人机控制指令

This commit is contained in:
2025-12-17 11:45:15 +08:00
parent 8990daf861
commit 17bed2438f
23 changed files with 2168 additions and 1774 deletions
+18 -4
View File
@@ -4,13 +4,19 @@
* - 生产环境由网关/容器转发,此文件不生效
*/
const GATEWAY = process.env.GATEWAY_ORIGIN || 'http://192.168.2.214:9900';
// WebSocket 网关地址(与 HTTP 网关相同)
const WS_GATEWAY = GATEWAY.replace('http://', 'ws://').replace('https://', 'wss://');
// SRS流媒体服务器地址
const SRS_SERVER = process.env.SRS_SERVER || 'http://220.205.16.27:8024';
export default {
dev: {
// 单一规则覆盖所有微服务前缀:/api-*
'/api-': { target: GATEWAY, changeOrigin: true },
// API 请求代理(HTTP)
// 注意:WebSocket 在 deviceControlWs.ts 中直接连接网关,不经过此代理
'/api-': {
target: GATEWAY,
changeOrigin: true,
},
// 3D模型CDN代理 - 解决跨域问题
'/goflymodel': {
target: 'https://minicdn.goflytec.com',
@@ -31,7 +37,11 @@ export default {
},
},
test: {
'/api-': { target: GATEWAY, changeOrigin: true },
'/api-': {
target: GATEWAY,
changeOrigin: true,
ws: true,
},
'/goflymodel': {
target: 'https://minicdn.goflytec.com',
changeOrigin: true,
@@ -39,7 +49,11 @@ export default {
},
},
pre: {
'/api-': { target: GATEWAY, changeOrigin: true },
'/api-': {
target: GATEWAY,
changeOrigin: true,
ws: true,
},
'/goflymodel': {
target: 'https://minicdn.goflytec.com',
changeOrigin: true,