-
Notifications
You must be signed in to change notification settings - Fork 112
docs: Add blog post for using pac git auth secret to avoid rate limit #2190
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
base: main
Are you sure you want to change the base?
docs: Add blog post for using pac git auth secret to avoid rate limit #2190
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a comprehensive documentation guide explaining how to use Pipelines-as-Code's git_auth_secret
variable to avoid rate limiting when fetching Git resources and accessing private repositories.
- Introduces a new blog post documenting the
git_auth_secret
feature and its usage patterns - Provides step-by-step instructions for implementing authenticated Git operations in Tekton pipelines
- Includes practical examples showing pipeline design and PipelineRun configuration
docs/content/docs/blog/using-pac-git-auth-secret-to-avoid-rate-limiting.md
Outdated
Show resolved
Hide resolved
docs/content/docs/blog/using-pac-git-auth-secret-to-avoid-rate-limiting.md
Outdated
Show resolved
Hide resolved
7b28a50
to
c5a478e
Compare
* Added new blog post `using-pac-git-auth-secret-to-avoid-rate-limiting.md`. * Explained how to use PaC's `{{ git_auth_secret }}` for authenticated Git operations. * Described how this mechanism helps prevent Git provider rate limiting. * Demonstrated accessing private Git resources securely within Tekton pipelines. * Updated `.gitignore` to exclude `.gemini` files. Co-authored-by: Gemini - gemini-2.5-pro Signed-off-by: Chmouel Boudjnah <chmouel@redhat.com>
c5a478e
to
e18cd46
Compare
|
||
Pipelines-as-Code (PaC) solves this elegantly by automatically generating a temporary, scoped authentication token for each `PipelineRun`. This token is stored in a Kubernetes `Secret`, and its name is made available to your `PipelineRun` through the built-in `{{ git_auth_secret }}` variable. | ||
|
||
This guide shows how to use `{{ git_auth_secret }}` to enable authenticated Git operations with the `git` resolver, helping you avoid rate-limiting and access private resources securely. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not to link this post with: https://github.com/tektoncd/community/blob/main/teps/0161-resolver-caching.md
|
||
You do not need to create any secrets manually. Simply reference the PaC variable `{{ git_auth_secret }}` in your `PipelineRun` template file (e.g., `.tekton/pipelinerun.yaml`). | ||
|
||
PaC will substitute this placeholder with the name of the auto-generated secret at runtime. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has a big limitation; it means that both the referred pipeline/task , and the project being built share the Git forge, IOW that the generated PaC secret may be used to authenticate against both of the repositories.
docs: Add guide for Git authentication secret to avoid rate limits
π Linked GitHub Issue
Fixes #
π¨π»β Linked Jira
π Type of Change
fix:
)feat:
)feat!:
,fix!:
)docs:
)chore:
)refactor:
)enhance:
)π§ͺ Testing Strategy
β Submitter Checklist
fix:
,feat:
) matches the "Type of Change" I selected above.make test
andmake lint
locally to check for and fix anyissues. For an efficient workflow, I have considered installing
pre-commit and running
pre-commit install
toautomate these checks.