Skip to content

Commit e2c291d

Browse files
committed
fix(ansible): invalid maxArtifacts annotation
When the maxArtifacts annotation can not be converted to an integer, do not use it.
1 parent 70efaa3 commit e2c291d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pkg/ansible/runner/runner.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,8 +174,9 @@ func (r *runner) Run(ident string, u *unstructured.Unstructured, kubeconfig stri
174174
i, err := strconv.Atoi(ma)
175175
if err != nil {
176176
log.Info("Invalid max runner artifact annotation", "err", err, "value", ma)
177+
} else {
178+
maxArtifacts = i
177179
}
178-
maxArtifacts = i
179180
}
180181

181182
go func() {

0 commit comments

Comments
 (0)