Uploaded image for project: 'Docs for Red Hat Developers'
  1. Docs for Red Hat Developers
  2. RHDEVDOCS-5727

Improve "Using Pipelines as Code with GitLab" example snippet in 1.10 docs

XMLWordPrintable

      Atm we do have in a note that private instances (i.e. self-hosted enterprise/private instances) of Gitlab are not automatically detected.

      However we could make it easier for the developers to grasp what do we mean, by adding said field (even in a commented out fashion) in the example

      Current state:

      apiVersion: "pipelinesascode.tekton.dev/v1alpha1"
      kind: Repository
      metadata:
        name: my-repo
        namespace: target-namespace
      spec:
        url: "https://gitlab.com/owner/repo" 
        git_provider:
          secret:
            name: "gitlab-webhook-config"
            key: "provider.token" # Set this if you have a different key in your secret
          webhook_secret:
            name: "gitlab-webhook-config"
            key: "webhook.secret" # Set this if you have a different key for your secret
      

      Suggested improvement state:

      apiVersion: "pipelinesascode.tekton.dev/v1alpha1"
      kind: Repository
      metadata:
        name: my-repo
        namespace: target-namespace
      spec:
        url: "https://gitlab.com/owner/repo" # See comment on spec.git_provider.url
        git_provider:
          url: "https://gitlab.example.com/ # Set this if you are using a private gitlab instance
          secret:
            name: "gitlab-webhook-config"
            key: "provider.token" # Set this if you have a different key in your secret
          webhook_secret:
            name: "gitlab-webhook-config"
            key: "webhook.secret" # Set this if you have a different key for your secret
      

      [1] https://docs.openshift.com/pipelines/1.10/pac/using-pipelines-as-code.html#using-pipelines-as-code-with-gitlab_using-pipelines-as-code

              rh-ee-mlungu Masauso Lungu (Inactive)
              rhn-support-mvalsecc Michele Valsecchi (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: