mirror of
https://github.com/go-gitea/gitea
synced 2025-07-27 04:38:36 +00:00
fix: do not init cron for actions when it's disabled
This commit is contained in:
@@ -7,10 +7,14 @@ import (
|
|||||||
"context"
|
"context"
|
||||||
|
|
||||||
user_model "code.gitea.io/gitea/models/user"
|
user_model "code.gitea.io/gitea/models/user"
|
||||||
|
"code.gitea.io/gitea/modules/setting"
|
||||||
actions_service "code.gitea.io/gitea/services/actions"
|
actions_service "code.gitea.io/gitea/services/actions"
|
||||||
)
|
)
|
||||||
|
|
||||||
func initActionsTasks() {
|
func initActionsTasks() {
|
||||||
|
if !setting.Actions.Enabled {
|
||||||
|
return
|
||||||
|
}
|
||||||
registerStopZombieTasks()
|
registerStopZombieTasks()
|
||||||
registerStopEndlessTasks()
|
registerStopEndlessTasks()
|
||||||
registerCancelAbandonedJobs()
|
registerCancelAbandonedJobs()
|
||||||
|
Reference in New Issue
Block a user