Skip to content

Commit 55f0b7e

Browse files
committed
📚 Sync docs from alaudadevops/tektoncd-operator on 9e1a9dc8a45ad0123347d5d61cf8a8b8890a49e3
Source: update triggertemplate_concept docs (#304) Author: tik-seven Ref: refs/heads/main Commit: 9e1a9dc8a45ad0123347d5d61cf8a8b8890a49e3 This commit automatically syncs documentation changes from the source-docs repository. 🔗 View source commit: AlaudaDevops/tektoncd-operator@9e1a9dc 🤖 Synced on 2025-08-11 09:24:02 UTC
1 parent 33e8fb6 commit 55f0b7e

File tree

2 files changed

+60
-3
lines changed

2 files changed

+60
-3
lines changed

‎.github/SYNC_INFO.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Documentation Sync Information
22

3-
- **Last synced**: 2025-08-11 08:21:47 UTC
3+
- **Last synced**: 2025-08-11 09:24:02 UTC
44
- **Source repository**: alaudadevops/tektoncd-operator
5-
- **Source commit**: [b2a7119ab75231d5dd9f04ff3ef836825a5e6c27](https://github.com/alaudadevops/tektoncd-operator/commit/b2a7119ab75231d5dd9f04ff3ef836825a5e6c27)
5+
- **Source commit**: [9e1a9dc8a45ad0123347d5d61cf8a8b8890a49e3](https://github.com/alaudadevops/tektoncd-operator/commit/9e1a9dc8a45ad0123347d5d61cf8a8b8890a49e3)
66
- **Triggered by**: tik-seven
7-
- **Workflow run**: [#32](https://github.com/alaudadevops/tektoncd-operator/actions/runs/16874693446)
7+
- **Workflow run**: [#33](https://github.com/alaudadevops/tektoncd-operator/actions/runs/16876030255)
88

99
## Files synced:
1010
- docs/

‎docs/en/triggers/concepts/triggertemplate_concept.mdx‎

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,8 @@ TriggerTemplates are essential in the following scenarios:
7070

7171
5. **Parameterized Testing**: Create test pipelines with different parameters based on the type of event.
7272

73+
6. **As Runtime Configuration Templates**: Provide standardized runtime configurations (such as parameters, workspaces, security contexts, etc.) for repeatedly executed Pipelines. Users can select matching templates through the frontend UI to quickly generate pipelinerun instances that meet scenario requirements.
74+
7375
## Constraints and Limitations
7476

7577
- Parameters in TriggerTemplates can only be string values
@@ -140,6 +142,28 @@ Each created resource receives labels to track its origin:
140142
- `tekton.dev/eventlistener: <EventListenerName>`
141143
- `tekton.dev/triggers-eventid: <EventID>`
142144

145+
### Runtime Configuration Templates
146+
147+
1. Label Conventions
148+
149+
- `triggertemplate.triggers.tekton.dev/usage: runtime-config`
150+
151+
Must be set to `runtime-config` to identify the purpose of the template.
152+
153+
- `tekton.dev/pipeline: <pipeline-name>`
154+
155+
Associates the template with a specific pipeline.
156+
157+
- `triggertemplate.triggers.tekton.dev/runtime-config-default: "true"`
158+
159+
Optional, marks the template as the default configuration for the pipeline. If multiple default templates exist, the one with the latest creation timestamp will be selected.
160+
161+
2. Resource Template Conventions
162+
163+
- Only one `PipelineRun` resource can be defined in `spec.resourcetemplates`.
164+
- Must include `pipelineRef` to reference the target pipeline.
165+
- Supports all runtime configuration fields of `PipelineRun`, such as `params`, `workspaces`, `podTemplate`, etc.
166+
143167
## Configuration Examples
144168

145169
### Basic CI Pipeline Template
@@ -242,6 +266,39 @@ spec:
242266
value: $(tt.params.git-revision)
243267
```
244268

269+
### Runtime Configuration Template
270+
271+
```yaml
272+
apiVersion: triggers.tekton.dev/v1beta1
273+
kind: TriggerTemplate
274+
metadata:
275+
name: deploy-pipeline-staging-config
276+
labels:
277+
triggertemplate.triggers.tekton.dev/usage: runtime-config
278+
tekton.dev/pipeline: deploy-pipeline
279+
triggertemplate.triggers.tekton.dev/runtime-config-default: true
280+
spec:
281+
resourcetemplates:
282+
- apiVersion: tekton.dev/v1
283+
kind: PipelineRun
284+
metadata:
285+
generateName: deploy-pipeline-staging-
286+
spec:
287+
pipelineRef:
288+
name: deploy-pipeline
289+
params:
290+
- name: environment
291+
value: "staging"
292+
- name: replicas
293+
value: "2"
294+
workspaces:
295+
- name: config
296+
configMap:
297+
name: staging-config
298+
```
299+
300+
301+
245302
## Important Parameter Explanations Related to TriggerTemplate
246303

247304
### Parameter Substitution

0 commit comments

Comments
 (0)