Skip to content

Conversation

@davidwtf
Copy link
Contributor

@davidwtf davidwtf commented Oct 31, 2025

Summary by CodeRabbit

Release Notes

  • Documentation
    • Added a comprehensive best-practices guide for pipelines in AI scenarios.
    • Explains GitLab-triggered, event-driven pipeline flows, webhook configuration, and two approaches to invoke downstream pipelines.
    • Details permissions, external exposure of listeners, trigger semantics, interceptors, and webhook secret handling.
    • Introduces Pipeline-as-Code workflows, repository conventions, controller access considerations, and end-to-end examples.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 31, 2025

Walkthrough

Adds a new, detailed Markdown guide describing best practices for orchestrating Tekton-based pipelines in AI scenarios: GitLab-triggered EventListeners, RoleBinding/ClusterRoleBinding, external EventListener exposure, Trigger/Interceptor/TriggerBinding usage, webhook secret handling, downstream triggering approaches, and Pipeline-as-Code (PAC) setup and examples (≤50 words).

Changes

Cohort / File(s) Summary
Documentation
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md
New comprehensive guide covering: EventListener setup for GitLab webhooks, RBAC (RoleBinding/ClusterRoleBinding), exposing EventListener (LoadBalancer), Trigger and Interceptor configurations (gitlab-push binding examples, param extraction), webhook secret management, methods to trigger downstream pipelines (PipelineRun vs custom events), TriggerBinding/ClusterTriggerBinding semantics, interceptors, and Pipeline-as-Code (PAC) installation, external access, repository conventions, GitLab webhook examples, and end-to-end YAML snippets.

Sequence Diagram(s)

sequenceDiagram
    participant GitLab as GitLab
    participant EL as EventListener
    participant IF as Interceptor
    participant TB as TriggerBinding
    participant Ctrl as Tekton Controller
    participant PR as PipelineRun

    rect rgb(240,248,255)
    GitLab->>EL: Send push webhook
    end

    rect rgb(255,250,240)
    EL->>IF: Forward payload to interceptor
    IF->>IF: Validate signature / filter event
    IF-->>EL: Emit filtered params
    end

    rect rgb(240,255,240)
    EL->>TB: Apply TriggerBinding (extract & map params)
    TB-->>EL: Bound template values
    EL->>Ctrl: Create PipelineRun resource
    Ctrl->>PR: Instantiate and start pipeline
    PR-->>PR: Execute tasks & report status
    end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20–30 minutes

  • Focus review on YAML examples for correct Tekton/Triggers/PAC API versions and field names.
  • Verify interceptor configurations (signature verification, event filtering) and TriggerBinding parameter mappings.
  • Check PAC installation and external access instructions for accuracy and security considerations.

Poem

🐰 I nibble docs by moonlit byte,
I hop through webhooks in the night.
Triggers hum and pipelines run,
PAC dreams bloom beneath the sun.
A rabbit cheers — well-crafted write! 🥕

Pre-merge checks and finishing touches

✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The pull request title "add Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md" accurately and directly describes the main change in the changeset. The title uses a clear "add" prefix convention and specifies the exact filename being introduced. The filename itself is descriptive and conveys meaningful information about the content (best practices for pipelines in AI scenarios), making it clear to teammates scanning repository history what was added. The title is concise, avoids vague language or noise, and fully captures the primary change.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch add/pipeline-best-practices

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (2)

176-176: Reduce phrasing repetition in method introduction.

The phrase "need to be introduced" appears to be used in nearby context, making the sentence feel repetitive. Rephrase for variety.

Consider rephrasing Line 176 from:

-To understand this method, some basic concepts of Tekton need to be introduced:
+To understand this method, review these core Tekton concepts:

148-148: Replace placeholder ellipsis with example or guidance.

Line 148 contains ...... as a placeholder for the base64-encoded secret value. While acceptable in documentation, consider adding a brief example or link to encoding instructions to improve usability.

Example improvement:

 data:
   webhook.secret: ......                  # Base64 encoded secret value
+                                          # Example: echo -n 'your-secret' | base64
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 18be136 and 6c98f8f.

📒 Files selected for processing (1)
  • docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (1 hunks)
🧰 Additional context used
🪛 LanguageTool
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md

[style] ~176-~176: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...s method, some basic concepts of Tekton need to be introduced: - EventListener: An...

(REP_NEED_TO_VB)

🪛 markdownlint-cli2 (0.18.1)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md

205-205: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


217-217: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


237-237: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


277-277: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


285-285: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)

🔇 Additional comments (2)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (2)

376-376: Clarify namespace inconsistency in example configurations.

The Repository resource is created in namespace demo-repo (Line 376), but the Secret example later shows namespace demo-namespace (Line 399). Clarify whether these resources should be in the same namespace or if this is intentional for your use case.

If these resources are meant to be in the same namespace, update Line 399 to:

 metadata:
   name: gitlab-webhook-config
-  namespace: demo-namespace
+  namespace: demo-repo

Alternatively, add a clarifying note explaining why they differ.

Also applies to: 399-399


1-482: Comprehensive documentation on pipeline orchestration—well structured and thorough.

The document provides detailed guidance on three key patterns: EventListener-based GitLab integration, cross-pipeline triggering via custom events, and Pipeline-as-Code. The progression from basic to advanced is logical, and the YAML examples are practical. The use of step-by-step instructions and curl verification commands adds clarity.

Minor notes for future expansion:

  • Consider adding troubleshooting tips or common error scenarios.
  • Note any prerequisites or version compatibility (e.g., minimum Tekton version, OpenShift vs. vanilla K8s differences).
  • Briefly introduce what "Alauda DevOps Pipelines" and "Alauda AI" are for readers unfamiliar with these products.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6c98f8f and 0f8a69e.

📒 Files selected for processing (1)
  • docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (1 hunks)
🧰 Additional context used
🪛 LanguageTool
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md

[style] ~185-~185: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...s method, some basic concepts of Tekton need to be introduced: - EventListener: An...

(REP_NEED_TO_VB)

🪛 markdownlint-cli2 (0.18.1)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md

214-214: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


226-226: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


246-246: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


286-286: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


294-294: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

♻️ Duplicate comments (1)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (1)

214-214: Convert step labels from bold emphasis to markdown headings.

These lines still use bold emphasis (**Step N: ...**) instead of proper markdown heading syntax. This violates markdownlint rule MD036 and degrades document structure. Convert all five step labels to level 3 headings (### Step N: ...) for proper navigation and formatting.

Apply this diff to fix all five step label lines:

-**Step 1: Define the Model Training Completion Event**
+### Step 1: Define the Model Training Completion Event

-**Step 2: Create the Corresponding TriggerBinding**
+### Step 2: Create the Corresponding TriggerBinding

-**Step 3: Create a Trigger to Use the Custom TriggerBinding**
+### Step 3: Create a Trigger to Use the Custom TriggerBinding

-**Step 4: Modify the EventListener Configuration**
+### Step 4: Modify the EventListener Configuration

-**Step 5: Send Events to Trigger Downstream Pipelines**
+### Step 5: Send Events to Trigger Downstream Pipelines

Also applies to: 226-226, 246-246, 286-286, 294-294

🧹 Nitpick comments (2)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (2)

419-419: Wrap bare URL in markdown link syntax.

Line 419 contains a bare URL, which violates markdownlint rule MD034. Wrap it in markdown link syntax for proper formatting and accessibility.

Apply this diff to fix the bare URL:

-> **Note**: Alternatively, the PAC CLI tool can be used to add repositories. See: https://pipelinesascode.com/docs/guide/cli/#repository-creation
+> **Note**: Alternatively, the PAC CLI tool can be used to add repositories. See: [PAC CLI Documentation](https://pipelinesascode.com/docs/guide/cli/#repository-creation)

185-185: Vary repeated phrasing for improved readability.

Line 185 reuses "need to be introduced" which appears nearby. Consider a synonym like "need to be explained" or "are important to understand" for better prose variety.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0f8a69e and 83625d9.

📒 Files selected for processing (1)
  • docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (1 hunks)
🧰 Additional context used
🪛 LanguageTool
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md

[style] ~185-~185: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing.
Context: ...s method, some basic concepts of Tekton need to be introduced: - EventListener: An...

(REP_NEED_TO_VB)

🪛 markdownlint-cli2 (0.18.1)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md

214-214: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


226-226: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


246-246: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


286-286: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


294-294: Emphasis used instead of a heading

(MD036, no-emphasis-as-heading)


419-419: Bare URL used

(MD034, no-bare-urls)

🔇 Additional comments (1)
docs/en/solutions/Best_Practices_for_Using_Pipelines_in_AI_Scenarios.md (1)

366-366: Clarify targetPort value for PAC controller Service.

Line 366 sets targetPort: 8082 while the LoadBalancer port is 8080. Verify this is intentional (the controller actually listens on 8082). A past review comment questioned whether the actual listening port is 8080, so confirm the target port is correct to avoid connectivity issues downstream.

@davidwtf davidwtf self-assigned this Nov 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants