fix(remote): 添加 /api/files/upload 路由支持文件上传

This commit is contained in:
2026-03-09 19:41:42 +08:00
parent d65b3e7909
commit 4c18edf74f
6 changed files with 302 additions and 4 deletions

View File

@@ -118,6 +118,11 @@ class App {
});
});
this.container.register('openCodeService', (c) => {
const OpenCodeService = require('../services/opencode/OpenCodeService');
return new OpenCodeService();
});
this.container.register('giteaService', (c) => {
const GiteaService = require('../services/network/GiteaService');
const config = c.resolve('config');
@@ -191,6 +196,10 @@ class App {
frpService.start();
logger.info('FRP service started');
const openCodeService = this.container.resolve('openCodeService');
openCodeService.start();
logger.info('OpenCode service started');
const giteaService = this.container.resolve('giteaService');
giteaService.start();
logger.info('Gitea service started');
@@ -469,6 +478,10 @@ class App {
frpService.stop();
logger.info('FRP service stopped');
const openCodeService = this.container.resolve('openCodeService');
openCodeService.stop();
logger.info('OpenCode service stopped');
const giteaService = this.container.resolve('giteaService');
giteaService.stop();
logger.info('Gitea service stopped');