mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-11-30 08:06:52 +02:00
sets default build timeout
This commit is contained in:
parent
6414d4e21e
commit
28061efeea
@ -120,7 +120,8 @@ func (r *Runner) Run(w *queue.Work) error {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
worker := newWorkerTimeout(client, w.Repo.Timeout+10) // 10 minute buffer
|
|
||||||
|
worker := newWorkerTimeout(client, w.Repo.Timeout)
|
||||||
workers = append(workers, worker)
|
workers = append(workers, worker)
|
||||||
cname := cname(task)
|
cname := cname(task)
|
||||||
state, builderr := worker.Build(cname, in)
|
state, builderr := worker.Build(cname, in)
|
||||||
|
@ -210,6 +210,7 @@ func PostRepo(c *gin.Context) {
|
|||||||
r.UserID = user.ID
|
r.UserID = user.ID
|
||||||
r.PostCommit = true
|
r.PostCommit = true
|
||||||
r.PullRequest = true
|
r.PullRequest = true
|
||||||
|
r.Timeout = 60 // 1 hour default build time
|
||||||
r.Self = fmt.Sprintf(
|
r.Self = fmt.Sprintf(
|
||||||
"%s/%s",
|
"%s/%s",
|
||||||
httputil.GetURL(c.Request),
|
httputil.GetURL(c.Request),
|
||||||
|
Loading…
Reference in New Issue
Block a user