Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document using Tekton Pipelines as prow jobs #44

Closed
VannTen opened this issue Jan 9, 2023 · 9 comments
Closed

Document using Tekton Pipelines as prow jobs #44

VannTen opened this issue Jan 9, 2023 · 9 comments
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@VannTen
Copy link
Contributor

VannTen commented Jan 9, 2023

I understand from kubernetes/test-infra#11888 that prow is able to run tekton pipelines as prow jobs.
However, it does not look like it's documented in docs.prow.k8s.io ("Tekton" search does not return any results)

From the PR conversation, it looks like a follow-up PR was planned, but never materialized (I guess that's the habitual fate of planned documentation 😄 ).

It looks like tekton has some docs on that ( https://github.com/tektoncd/plumbing/blob/main/docs/prow.md#tekton-pipelines-with-prow ). But as far as I understand, it applies to their prow instance, not in general.

kubernetes/test-infra#13874 seems also relevant, in particular the third comment, but I'm not sure how much has changed since that ?

@Gregory-Pereira you might be interested.

@qaifshaikh
Copy link

The only major breaking change I see is the deprecation of PipelineResources which was used for the clonerefs through PROW_IMPLICIT_GIT_REF

@VannTen
Copy link
Contributor Author

VannTen commented Jan 26, 2023

You mean in regard to kubernetes/test-infra#13874 (comment) ?
(And what would be the replacement ?)

@qaifshaikh
Copy link

Yeah, I'm not sure how PROW_IMPLICIT_GIT_REF works and it is definitely better than having the git-clone tekton task as part of the pipeline.
I believe @cjwagner proposed it long time ago

@qaifshaikh
Copy link

I was able to get the tekton PipelineRun working on my setup only because PipelineResource is deprecated in v0.36.0. It is removed in the next versions on Tekton so it'll probably stop working!

presubmit.yaml

presubmits:
  {REPO_OWNER}/{REPO}:
  - name: tekton-test
    agent: tekton-pipeline # Use the Prow Tekton controller!
    clone_uri: "git@github.com:{REPO_OWNER}/{REPO}.git"
    always_run: true
    skip_report: false
    rerun_command: /test tekton-test
    trigger: "(?m)^/test (all|tekton-test),?(\\s+|$)"
    pipeline_run_spec:
      serviceAccountName: prow-pipeline
      pipelineRef:
        name: hello-goodbye
      resources:
      - name: clone
        resourceRef:
          name: PROW_IMPLICIT_GIT_REF

pipeline.yaml

apiVersion: tekton.dev/v1beta1
kind: Pipeline
metadata:
  name: hello-goodbye
spec:
  tasks:
    - name: hello
      taskRef:
        name: hello
      resources:
        inputs:
          - name: clone
            resource: clone
    - name: goodbye
      runAfter:
        - hello
      taskRef:
        name: goodbye
      resources:
        inputs:
          - name: clone
            resource: clone
  resources:
    - name: clone
      type: git

task.yaml

apiVersion: tekton.dev/v1beta1
kind: Task
metadata:
  name: hello
spec:
  resources:
    inputs:
      - name: clone
        type: git
  steps:
    - name: echo
      image: alpine
      script: |
        #!/bin/sh
        echo "Hello World"
---
apiVersion: tekton.dev/v1beta1
kind: Task
metadata:
  name: goodbye
spec:
  resources:
    inputs:
      - name: clone
        type: git
  steps:
    - name: goodbye
      image: ubuntu
      script: |
        #!/bin/bash
        echo "Goodbye World!"

@qaifshaikh
Copy link

Also found this which makes a lot of sense!

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle stale
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 1, 2023
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle rotten
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels May 31, 2023
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

@k8s-ci-robot
Copy link
Contributor

@k8s-triage-robot: Closing this issue, marking it as "Not Planned".

In response to this:

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot closed this as not planned Won't fix, can't repro, duplicate, stale Jun 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

No branches or pull requests

4 participants