π The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.
Vue dockergolangkanbanknowledge-baseknowledge-managementmarkdownnote-takingnotesnotes-appnotionnuxtnuxtjsoffline-firstoidcpwaselfhostedssovuevuejswiki
feat: support disable of native login
Smaug6739215a3a7166ec
diff --git a/backend/controllers/authentication.controller.go b/backend/controllers/authentication.controller.goindex c38c5ba0..ca42555e 100644--- a/backend/controllers/authentication.controller.go+++ b/backend/controllers/authentication.controller.go@@ -60,6 +60,11 @@ type AuthClaims struct {}func (ctr *Controller) Login(c *gin.Context) (int, any) {++ if disabled := os.Getenv("CONFIG_DISABLE_NATIVE_LOGIN"); disabled == "true" {+ return http.StatusForbidden, errors.New("native login is disabled")+ }+var authClaims AuthClaimsif err := c.ShouldBind(&authClaims); err != nil {return http.StatusBadRequest, err