mirror of
https://gitea.toothfairyai.com/ToothFairyAI/tf_code.git
synced 2026-03-31 14:22:27 +00:00
core: rename OPENCODE_PASSWORD to OPENCODE_SERVER_PASSWORD for clearer authentication configuration
This commit is contained in:
@@ -98,9 +98,10 @@ export namespace Server {
|
||||
})
|
||||
})
|
||||
.use((c, next) => {
|
||||
const password = Flag.OPENCODE_PASSWORD
|
||||
const password = Flag.OPENCODE_SERVER_PASSWORD
|
||||
if (!password) return next()
|
||||
return basicAuth({ username: "opencode", password })(c, next)
|
||||
const username = Flag.OPENCODE_SERVER_USERNAME ?? "opencode"
|
||||
return basicAuth({ username, password })(c, next)
|
||||
})
|
||||
.use(async (c, next) => {
|
||||
const skipLogging = c.req.path === "/log"
|
||||
|
||||
Reference in New Issue
Block a user