mirror of
https://github.com/harness/drone.git
synced 2025-05-21 19:39:59 +08:00
decrease parallel workers to 2 for CI (#522)
This commit is contained in:
parent
dfe539c67d
commit
094c14049a
@ -200,6 +200,7 @@ func convertToDroneBuild(execution *types.Execution) *drone.Build {
|
|||||||
func convertToDroneRepo(repo *types.Repository) *drone.Repo {
|
func convertToDroneRepo(repo *types.Repository) *drone.Repo {
|
||||||
return &drone.Repo{
|
return &drone.Repo{
|
||||||
ID: repo.ID,
|
ID: repo.ID,
|
||||||
|
Trusted: true, // as builds are running on user machines, the repo is marked trusted.
|
||||||
UID: repo.UID,
|
UID: repo.UID,
|
||||||
UserID: repo.CreatedBy,
|
UserID: repo.CreatedBy,
|
||||||
Name: repo.UID,
|
Name: repo.UID,
|
||||||
|
@ -149,8 +149,6 @@ func (t *triggerer) Trigger(
|
|||||||
return t.createExecutionWithError(ctx, pipeline, base, err.Error())
|
return t.createExecutionWithError(ctx, pipeline, base, err.Error())
|
||||||
}
|
}
|
||||||
|
|
||||||
verified := true
|
|
||||||
|
|
||||||
var matched []*yaml.Pipeline
|
var matched []*yaml.Pipeline
|
||||||
var dag = dag.New()
|
var dag = dag.New()
|
||||||
for _, document := range manifest.Resources {
|
for _, document := range manifest.Resources {
|
||||||
@ -237,9 +235,7 @@ func (t *triggerer) Trigger(
|
|||||||
if stage.Name == "" {
|
if stage.Name == "" {
|
||||||
stage.Name = "default"
|
stage.Name = "default"
|
||||||
}
|
}
|
||||||
if verified == false {
|
if len(stage.DependsOn) == 0 {
|
||||||
stage.Status = enum.CIStatusBlocked
|
|
||||||
} else if len(stage.DependsOn) == 0 {
|
|
||||||
stage.Status = enum.CIStatusPending
|
stage.Status = enum.CIStatusPending
|
||||||
}
|
}
|
||||||
stages = append(stages, stage)
|
stages = append(stages, stage)
|
||||||
|
@ -88,7 +88,7 @@ type Config struct {
|
|||||||
|
|
||||||
// CI defines configuration related to build executions.
|
// CI defines configuration related to build executions.
|
||||||
CI struct {
|
CI struct {
|
||||||
ParallelWorkers int `envconfig:"GITNESS_CI_PARALLEL_WORKERS" default:"5"`
|
ParallelWorkers int `envconfig:"GITNESS_CI_PARALLEL_WORKERS" default:"2"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Database defines the database configuration parameters.
|
// Database defines the database configuration parameters.
|
||||||
|
Loading…
Reference in New Issue
Block a user