1
0
Fork 0
forked from forgejo/forgejo

Add admin dashboard option to run health checks (#3606)

There's one for git gc, why not git fsck too?

Also add a couple more trace logs to GitFsck to see progress
This commit is contained in:
Allen Wild 2018-03-02 04:09:43 -05:00 committed by Lauris BH
parent 2cd3622ddc
commit 8606d9f5bc
4 changed files with 12 additions and 0 deletions

View file

@ -122,6 +122,7 @@ const (
syncRepositoryUpdateHook
reinitMissingRepository
syncExternalUsers
gitFsck
)
// Dashboard show admin panel dashboard
@ -161,6 +162,9 @@ func Dashboard(ctx *context.Context) {
case syncExternalUsers:
success = ctx.Tr("admin.dashboard.sync_external_users_started")
go models.SyncExternalUsers()
case gitFsck:
success = ctx.Tr("admin.dashboard.git_fsck_started")
go models.GitFsck()
}
if err != nil {