You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: Add PipelineRun support to BuildRun reconciler
This commit introduces PipelineRun support to the BuildRun
reconciler, enabling Shipwright to use Tekton PipelineRuns as an alternative
to TaskRuns for build execution.
Key changes:
- Add pipelinerun_runner.go with TektonPipelineRunWrapper implementation
that wraps Tekton PipelineRuns and injects TaskRun specs into PipelineRun
structures.
- Implement ImageBuildRunner and ImageBuildRunnerFactory interfaces for
PipelineRun support.
- Add reconciliation logic for PipelineRun status updates, including
condition handling and failure detection
- Add UpdateBuildRunUsingPipelineRunCondition function to update BuildRun
status based on PipelineRun conditions (timeout, cancellation, success,
failure)
- Refactor volume checking to use GetUnderlyingTaskRun() method for both
TaskRun and PipelineRun executors, eliminating the need for separate
volume checking methods
- Add RunnerFactories map to support configurable executor selection
between TaskRun and PipelineRun implementations
- Update error handling in CreateImageBuildRunner
- Add UpdateImageBuildRunFromExecutor to handle updating Buildrun based on
used executor (pipelinerun or taskrun)
The implementation maintains backward compatibility.
Signed-off-by: Hasan Awad <[email protected]>
Copy file name to clipboardExpand all lines: deploy/200-role.yaml
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -67,6 +67,10 @@ rules:
67
67
# With the OwnerReferencesPermissionEnforcement admission controller enabled, controllers need the "delete" permission on objects that they set owner references on.
Copy file name to clipboardExpand all lines: docs/configuration.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,7 @@ The following environment variables are available:
37
37
|`KUBE_API_BURST`| Burst to use for the Kubernetes API client. See [Config.Burst]. A value of 0 or lower will use the default from client-go, which currently is 10. Default is 0. |
38
38
|`KUBE_API_QPS`| QPS to use for the Kubernetes API client. See [Config.QPS]. A value of 0 or lower will use the default from client-go, which currently is 5. Default is 0. |
39
39
|`VULNERABILITY_COUNT_LIMIT`| holds vulnerability count limit if vulnerability scan is enabled for the output image. If it is defined as 10, then it will output only 10 vulnerabilities sorted by severity in the buildrun status.Output. Default is 50. |
40
+
|`BUILDRUN_EXECUTOR`| Sets the kind of buildrun exectutor that will be used. Value can be `TaskRun` or `PipelineRun`. By default buildrun will use `TaskRun` for its build executor. |
40
41
41
42
[^1]: The `runAsUser` and `runAsGroup` are dynamically overwritten depending on the build strategy that is used. See [Security Contexts](buildstrategies.md#security-contexts) for more information.
0 commit comments