triggers icon indicating copy to clipboard operation
triggers copied to clipboard

Mystery clusterrole reference in docs/getting-started

Open waltforme opened this issue 2 years ago • 1 comments

Expected Behavior

The roleRef of the tekton-triggers-getting-started-clusterbinding clusterrolebinding in docs/getting-started/rbac/clusterrolebinding.yaml refers to some real clusterrole.

Actual Behavior

The roleRef refers to a clusterrole tekton-triggers-example-clusterrole which doesn't exist.

Steps to Reproduce the Problem

  1. The referred clusterrole tekton-triggers-example-clusterrole only appears once in this repository.
$ grep tekton-triggers-example-clusterrole -rn .
./docs/getting-started/rbac/clusterrolebinding.yaml:12:  name: tekton-triggers-example-clusterrole
  1. The referred clusterrole tekton-triggers-example-clusterrole doesn't exist in a cluster with Tekton Pipelines and Tekton Triggers installed.
$ kubectl get clusterrole | grep tekton
tekton-aggregate-edit                                                  2022-09-20T07:12:33Z
tekton-aggregate-view                                                  2022-09-20T07:12:33Z
tekton-pipelines-controller-cluster-access                             2022-09-20T07:12:31Z
tekton-pipelines-controller-tenant-access                              2022-09-20T07:12:31Z
tekton-pipelines-webhook-cluster-access                                2022-09-20T07:12:31Z
tekton-triggers-admin                                                  2022-09-24T07:25:22Z
tekton-triggers-aggregate-edit                                         2022-09-24T07:25:26Z
tekton-triggers-aggregate-view                                         2022-09-24T07:25:26Z
tekton-triggers-core-interceptors                                      2022-09-24T07:25:22Z
tekton-triggers-core-interceptors-secrets                              2022-09-24T07:25:23Z
tekton-triggers-eventlistener-clusterroles                             2022-09-24T07:25:23Z
tekton-triggers-eventlistener-roles                                    2022-09-24T07:25:23Z

Additional Info

  • Kubernetes version:

    Output of kubectl version:

Client Version: version.Info{Major:"1", Minor:"24", GitVersion:"v1.24.0", GitCommit:"4ce5a8954017644c5420bae81d72b09b735c21f0", GitTreeState:"clean", BuildDate:"2022-05-03T13:46:05Z", GoVersion:"go1.18.1", Compiler:"gc", Platform:"darwin/amd64"}
Kustomize Version: v4.5.4
Server Version: version.Info{Major:"1", Minor:"25", GitVersion:"v1.25.0", GitCommit:"a866cbe2e5bbaa01cfd5e969aa3e033f3282a8a2", GitTreeState:"clean", BuildDate:"2022-08-23T17:38:15Z", GoVersion:"go1.19", Compiler:"gc", Platform:"linux/amd64"}
  • Tekton Pipeline version:

    Client version: 0.26.0 Pipeline version: v0.40.0 Triggers version: v0.21.0

  • The tutorial documented by docs/getting-started/README.md works anyway, even if the clusterrole tekton-triggers-example-clusterrole doesn't exist.

  • docs/getting-started/README.md instructs readers to delete the getting-started namespace for cleaning up. But the cluster scoped RBAC objects, e.g. clusterrolebindings, won't get cleaned.

  • I can see the the Tekton website is not using docs/getting-started, but I guess there is not harm to fix it :)

waltforme avatar May 05 '23 19:05 waltforme

@tektoncd/triggers-maintainers Should the getting-started doc in the Triggers repo be removed? It looks like the content of the readme hasn't been updated in 2 years.

The Triggers getting started guide displayed on the website comes from the website repo instead and was added at the end of 2022: https://github.com/tektoncd/website/blob/main/content/en/docs/Getting-started/triggers.md

It could be confusing having 2 different versions, as it's not immediately clear to users which is correct / current.

AlanGreene avatar May 08 '23 17:05 AlanGreene