refactor(backend): 修改后端默认端口 30002

This commit is contained in:
ApplePine 2025-06-21 04:15:17 +08:00
parent ac70cca4a2
commit 3d89dff22f
3 changed files with 26 additions and 15 deletions

View File

@ -1,15 +1,18 @@
{
"name": "free_backend",
"scripts": {
"dev": "bun run --hot src/index.ts"
},
"dependencies": {
"axios": "^1.10.0",
"hono": "^4.8.1"
},
"devDependencies": {
"@types/bun": "latest",
"eslint": "^9.29.0",
"prettier": "^3.5.3"
}
}
"name": "free_backend",
"scripts": {
"dev": "bun run --hot src/index.ts",
"build": "bun build ./server.ts --outdir=./dist --target bun",
"compile": "bun build ./server.ts --compile --outfile server",
"start": "bun run ./dist/server.js"
},
"dependencies": {
"axios": "^1.10.0",
"hono": "^4.8.1"
},
"devDependencies": {
"@types/bun": "latest",
"eslint": "^9.29.0",
"prettier": "^3.5.3"
}
}

View File

@ -0,0 +1,8 @@
import server from './src/index'
const { app, port } = server
export default {
port,
fetch: app.fetch,
}

View File

@ -69,4 +69,4 @@ app.get('/api/searchvideo', async (c) => {
}
})
export default app
export default { app, port: 30002 }