test-infra

module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 3, 2023 License: Apache-2.0

README

test-infra

GoDoc Build status

This repository contains tools and configuration files for the testing and automation needs of the Kubernetes project.

Our architecture diagram provides an (updated #13063) overview of how the different tools and services interact.

CI Job Management

Kubernetes uses a prow instance at prow.k8s.io to handle CI and automation for the entire project. Everyone can participate in a self-service PR-based workflow, where changes are automatically deployed after they have been reviewed. All job configs are located in config/jobs

Dashboards

Test Result Dashboards
Job and PR Dashboards

Other Tools

  • boskos manages pools of resources; our CI leases GCP projects from these pools
  • experiment is a catchall directory for one-shot tools or scripts
  • gcsweb is a UI we use to display test artifacts stored in public GCS buckets
  • ghproxy is a GitHub-aware reverse proxy cache to help keep our GitHub API token usage within rate limits
  • gopherage is a tool for manipulating Go coverage files
  • greenhouse is a shared bazel cache we use to ensure faster build and test presubmit jobs
  • label_sync creates, updates and migrates GitHub labels across orgs and repos based on labels.yaml file
  • kettle extracts test results from GCS and puts them into bigquery
  • kubetest is how our CI creates and e2e tests kubernetes clusters
  • maintenance/migratestatus is used to migrate or retire GitHub status contexts on PRs across orgs and repos
  • metrics runs queries against bigquery to generate metrics based on test results
  • robots/commenter is used by some of our jobs to comment on GitHub issues

Contributing

Please see CONTRIBUTING.MD

Directories

Path Synopsis
def
configmap
configmap will write a configmap to --output from --data=name=/path/to/source
configmap will write a configmap to --output from --data=name=/path/to/source
experiment
ci-janitor
ci-janitor cleans up dedicated projects in k8s prowjob configs
ci-janitor cleans up dedicated projects in k8s prowjob configs
manual-trigger
manual-trigger triggers jenkins jobs based a specified github pull request
manual-trigger triggers jenkins jobs based a specified github pull request
ml/prowlog
Package main will process annotated builds listed in the tsv file.
Package main will process annotated builds listed in the tsv file.
ml/prowlog/csv
Package main will create a CSV dataset by reading the specified zip file.
Package main will create a CSV dataset by reading the specified zip file.
gcsweb
ghcache
Package ghcache implements an HTTP cache optimized for caching responses from the GitHub API (https://api.github.com).
Package ghcache implements an HTTP cache optimized for caching responses from the GitHub API (https://api.github.com).
pkg/cov/junit/calculation
Package calculation calculates coverage through summarizing and filtering.
Package calculation calculates coverage through summarizing and filtering.
greenhouse implements a bazel remote cache service [1] supporting arbitrarily many workspaces stored within the same top level directory.
greenhouse implements a bazel remote cache service [1] supporting arbitrarily many workspaces stored within the same top level directory.
diskcache
Package diskcache implements disk backed cache storage for use in greenhouse
Package diskcache implements disk backed cache storage for use in greenhouse
diskutil
Package diskutil implements disk related utilities for greenhouse
Package diskutil implements disk related utilities for greenhouse
hack
images
Package main / gke.go provides the Google Container Engine (GKE) kubetest deployer via newGKE().
Package main / gke.go provides the Google Container Engine (GKE) kubetest deployer via newGKE().
conformance
Package conformance implements conformance test kubetest code.
Package conformance implements conformance test kubetest code.
e2e
This is a label_sync tool, details in README.md
This is a label_sync tool, details in README.md
logexporter
cmd
maintenance
pkg
flagutil
Package flagutil contains utilities and interfaces shared between several test-infra commands.
Package flagutil contains utilities and interfaces shared between several test-infra commands.
genyaml
Package genyaml can generate an example YAML snippet from an initialized struct and decorate it with godoc comments parsed from the AST of a given file.
Package genyaml can generate an example YAML snippet from an initialized struct and decorate it with godoc comments parsed from the AST of a given file.
ghclient
Package ghclient provides a github client that wraps go-github with retry logic, rate limiting, and depagination where necessary.
Package ghclient provides a github client that wraps go-github with retry logic, rate limiting, and depagination where necessary.
prow
apis/prowjobs/v1
Package v1 is the v1 version of the API.
Package v1 is the v1 version of the API.
client/clientset/versioned
This package has the automatically generated clientset.
This package has the automatically generated clientset.
client/clientset/versioned/fake
This package has the automatically generated fake clientset.
This package has the automatically generated fake clientset.
client/clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
This package contains the scheme of the automatically generated clientset.
client/clientset/versioned/typed/prowjobs/v1
This package has the automatically generated typed clients.
This package has the automatically generated typed clients.
client/clientset/versioned/typed/prowjobs/v1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.
clonerefs
Package clonerefs is a library for cloning references
Package clonerefs is a library for cloning references
cmd/checkconfig
checkconfig loads configuration for Prow to validate it
checkconfig loads configuration for Prow to validate it
cmd/gcsupload
gcsupload uploads the files and folders specified to GCS using the Prow-defined job configuration
gcsupload uploads the files and folders specified to GCS using the Prow-defined job configuration
cmd/initupload
initupload parses the logs from the clonerefs container and determines if that container was successful or not.
initupload parses the logs from the clonerefs container and determines if that container was successful or not.
cmd/tot
Tot vends (rations) incrementing numbers for use in builds.
Tot vends (rations) incrementing numbers for use in builds.
cmd/tot/fallbackcheck
fallbackcheck reports whether jobs in the provided prow deployment have fallback build numbers in GCS.
fallbackcheck reports whether jobs in the provided prow deployment have fallback build numbers in GCS.
commentpruner
Package commentpruner facilitates efficiently deleting bot comments as a reaction to webhook events.
Package commentpruner facilitates efficiently deleting bot comments as a reaction to webhook events.
config
Package config knows how to read and parse config.yaml.
Package config knows how to read and parse config.yaml.
config/secret
Package secret implements an agent to read and reload the secrets.
Package secret implements an agent to read and reload the secrets.
crier
Package crier reports finished prowjob status to git providers.
Package crier reports finished prowjob status to git providers.
crier/reporters/criercommonlib
Package criercommonlib contains shared lib used by reporters
Package criercommonlib contains shared lib used by reporters
crier/reporters/gerrit
Package reporter implements a reporter interface for gerrit
Package reporter implements a reporter interface for gerrit
crier/reporters/github
Package reporter implements a reporter interface for github TODO(krzyzacy): move logic from report.go here
Package reporter implements a reporter interface for github TODO(krzyzacy): move logic from report.go here
crier/reporters/pubsub
Package reporter contains helpers for publishing statues to Pub statuses in GitHub.
Package reporter contains helpers for publishing statues to Pub statuses in GitHub.
cron
Package cron provides a wrapper of robfig/cron, which manages schedule cron jobs for horologium
Package cron provides a wrapper of robfig/cron, which manages schedule cron jobs for horologium
deck/jobs
Package jobs implements methods on job information used by Prow component deck
Package jobs implements methods on job information used by Prow component deck
entrypoint
Package entrypoint is a library that knows how to wrap a process and write it's output and exit code to disk
Package entrypoint is a library that knows how to wrap a process and write it's output and exit code to disk
external-plugins/refresh
Refresh retries GitHub status updates for stale PR statuses.
Refresh retries GitHub status updates for stale PR statuses.
flagutil
Package flagutil contains utilities and interfaces shared between several Prow commands.
Package flagutil contains utilities and interfaces shared between several Prow commands.
gcsupload
Package gcsupload uploads artifacts to a GCS path resolved from job configuration
Package gcsupload uploads artifacts to a GCS path resolved from job configuration
genfiles
Package genfiles understands the .generated_files config file.
Package genfiles understands the .generated_files config file.
gerrit/adapter
Package adapter implements a controller that interacts with gerrit instances
Package adapter implements a controller that interacts with gerrit instances
gerrit/client
Package client implements a client that can handle multiple gerrit instances derived from https://github.com/andygrunwald/go-gerrit
Package client implements a client that can handle multiple gerrit instances derived from https://github.com/andygrunwald/go-gerrit
gerrit/source
Package source contains functions that help with Gerrit source control specific logics.
Package source contains functions that help with Gerrit source control specific logics.
git
Package git provides a client to plugins that can do git operations.
Package git provides a client to plugins that can do git operations.
git/localgit
Package localgit creates a local git repo that can be used for testing code that uses a git.Client.
Package localgit creates a local git repo that can be used for testing code that uses a git.Client.
git/types
Package types stores types used by all git clients
Package types stores types used by all git clients
github/report
Package report contains helpers for writing comments and updating statuses in GitHub.
Package report contains helpers for writing comments and updating statuses in GitHub.
initupload
Package initupload determines the output status of clone operations and posts that status along with artifacts and logs to cloud storage.
Package initupload determines the output status of clone operations and posts that status along with artifacts and logs to cloud storage.
interrupts
Package interrupts exposes helpers for graceful handling of interrupt signals
Package interrupts exposes helpers for graceful handling of interrupt signals
io
jenkins
Package jenkins includes a client and the operational logic for managing Jenkins masters in prow.
Package jenkins includes a client and the operational logic for managing Jenkins masters in prow.
logrusutil
Package logrusutil implements some helpers for using logrus
Package logrusutil implements some helpers for using logrus
metrics
Package metrics contains utilities for working with metrics in prow.
Package metrics contains utilities for working with metrics in prow.
pipeline/clientset/versioned
This package has the automatically generated clientset.
This package has the automatically generated clientset.
pipeline/clientset/versioned/fake
This package has the automatically generated fake clientset.
This package has the automatically generated fake clientset.
pipeline/clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
This package contains the scheme of the automatically generated clientset.
pipeline/clientset/versioned/typed/pipeline/v1alpha1
This package has the automatically generated typed clients.
This package has the automatically generated typed clients.
pipeline/clientset/versioned/typed/pipeline/v1alpha1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.
pipeline/clientset/versioned/typed/pipeline/v1beta1
This package has the automatically generated typed clients.
This package has the automatically generated typed clients.
pipeline/clientset/versioned/typed/pipeline/v1beta1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.
pjutil
Package pjutil contains helpers for working with ProwJobs.
Package pjutil contains helpers for working with ProwJobs.
pjutil/pprof
Package pprof contains helpers for profiling binaries.
Package pprof contains helpers for profiling binaries.
pluginhelp
Package pluginhelp defines structures that represent plugin help information.
Package pluginhelp defines structures that represent plugin help information.
pluginhelp/externalplugins
Package externalplugins provides the plugin help components to be compiled into external plugin binaries.
Package externalplugins provides the plugin help components to be compiled into external plugin binaries.
pluginhelp/hook
Package hook provides the plugin help components to be compiled into the hook binary.
Package hook provides the plugin help components to be compiled into the hook binary.
plugins/blockade
Package blockade defines a plugin that adds the 'do-not-merge/blocked-paths' label to PRs that modify protected file paths.
Package blockade defines a plugin that adds the 'do-not-merge/blocked-paths' label to PRs that modify protected file paths.
plugins/bugzilla
Package bugzilla ensures that pull requests reference a Bugzilla bug in their title
Package bugzilla ensures that pull requests reference a Bugzilla bug in their title
plugins/buildifier
Package buildifier defines a Prow plugin that runs buildifier over modified BUILD, WORKSPACE, and skylark (.bzl) files in pull requests.
Package buildifier defines a Prow plugin that runs buildifier over modified BUILD, WORKSPACE, and skylark (.bzl) files in pull requests.
plugins/cat
Package cat adds cat images to an issue or PR in response to a /meow comment
Package cat adds cat images to an issue or PR in response to a /meow comment
plugins/cherrypickunapproved
Package cherrypickunapproved adds the `do-not-merge/cherry-pick-not-approved` label to PRs against a release branch which do not have the `cherry-pick-approved` label.
Package cherrypickunapproved adds the `do-not-merge/cherry-pick-not-approved` label to PRs against a release branch which do not have the `cherry-pick-approved` label.
plugins/dco
Package dco implements a DCO (https://developercertificate.org/) checker plugin
Package dco implements a DCO (https://developercertificate.org/) checker plugin
plugins/dog
Package dog adds dog images to the issue or PR in response to a /woof comment
Package dog adds dog images to the issue or PR in response to a /woof comment
plugins/goose
Package goose adds goose images to an issue or PR in response to a /honk comment
Package goose adds goose images to an issue or PR in response to a /honk comment
plugins/hold
Package hold contains a plugin which will allow users to label their own pull requests as not ready or ready for merge.
Package hold contains a plugin which will allow users to label their own pull requests as not ready or ready for merge.
plugins/invalidcommitmsg
Package invalidcommitmsg adds the "do-not-merge/invalid-commit-message" label on PRs containing commit messages with @mentions or keywords that can automatically close issues.
Package invalidcommitmsg adds the "do-not-merge/invalid-commit-message" label on PRs containing commit messages with @mentions or keywords that can automatically close issues.
plugins/lgtm
Package lgtm implements the lgtm plugin
Package lgtm implements the lgtm plugin
plugins/merge-method-comment
Package mergemethodcomment contains a Prow plugin which comments on PRs with 2 or more commits, informing the user: - How to request commits to be squashed if default merge method is merge, - How to request commits to be merged if the repo squashes commits by default, - That the commits will be merged/squashed if it is not possible to override the default merge method.
Package mergemethodcomment contains a Prow plugin which comments on PRs with 2 or more commits, informing the user: - How to request commits to be squashed if default merge method is merge, - How to request commits to be merged if the repo squashes commits by default, - That the commits will be merged/squashed if it is not possible to override the default merge method.
plugins/milestone
Package milestone implements the `/milestone` command which allows members of the milestone maintainers team to specify a milestone to be applied to an Issue or PR.
Package milestone implements the `/milestone` command which allows members of the milestone maintainers team to specify a milestone to be applied to an Issue or PR.
plugins/milestoneapplier
Package milestoneapplier implements the plugin to automatically apply the configured milestone after a PR is merged.
Package milestoneapplier implements the plugin to automatically apply the configured milestone after a PR is merged.
plugins/milestonestatus
Package milestonestatus implements the `/status` command which allows members of the milestone maintainers team to specify a `status/*` label to be applied to an Issue or PR.
Package milestonestatus implements the `/status` command which allows members of the milestone maintainers team to specify a `status/*` label to be applied to an Issue or PR.
plugins/override
Package override supports the /override context command.
Package override supports the /override context command.
plugins/pony
Package pony adds pony images to the issue or PR in response to a /pony comment
Package pony adds pony images to the issue or PR in response to a /pony comment
plugins/project
Package project implements the `/project` command which allows members of the project maintainers team to specify a project to be applied to an Issue or PR.
Package project implements the `/project` command which allows members of the project maintainers team to specify a project to be applied to an Issue or PR.
plugins/projectmanager
Package projectmanager is a plugin to auto add pull requests to project boards based on specified conditions
Package projectmanager is a plugin to auto add pull requests to project boards based on specified conditions
plugins/require-matching-label
Package requirematchinglabel implements the `require-matching-label` plugin.
Package requirematchinglabel implements the `require-matching-label` plugin.
plugins/retitle
Package retitle implements the retitle plugin
Package retitle implements the retitle plugin
plugins/sigmention
Package sigmention recognize SIG '@' mentions and adds 'sig/*' and 'kind/*' labels as appropriate.
Package sigmention recognize SIG '@' mentions and adds 'sig/*' and 'kind/*' labels as appropriate.
plugins/size
Package size contains a Prow plugin which counts the number of lines changed in a pull request, buckets this number into a few size classes (S, L, XL, etc), and finally labels the pull request with this size.
Package size contains a Prow plugin which counts the number of lines changed in a pull request, buckets this number into a few size classes (S, L, XL, etc), and finally labels the pull request with this size.
plugins/skip
Package skip implements the `/skip` command which allows users to clean up commit statuses of non-blocking presubmits on PRs.
Package skip implements the `/skip` command which allows users to clean up commit statuses of non-blocking presubmits on PRs.
plugins/stage
Package stage defines a Prow plugin that defines the stage of the issue in the features process.
Package stage defines a Prow plugin that defines the stage of the issue in the features process.
plugins/testfreeze/checker/checkerfakes
Code generated by counterfeiter.
Code generated by counterfeiter.
plugins/testfreeze/testfreezefakes
Code generated by counterfeiter.
Code generated by counterfeiter.
plugins/transfer-issue
Package transferissue implements the `/transfer-issue` command which allows members of the org to transfer issues between repos
Package transferissue implements the `/transfer-issue` command which allows members of the org to transfer issues between repos
plugins/trick-or-treat
Package trickortreat adds halloween images to an issue or PR in response to a /trick-or-treat comment
Package trickortreat adds halloween images to an issue or PR in response to a /trick-or-treat comment
plugins/welcome
Package welcome implements a prow plugin to welcome new contributors
Package welcome implements a prow plugin to welcome new contributors
plugins/wip
Package wip will label a PR a work-in-progress if the author provides a prefix to their pull request title to the same effect.
Package wip will label a PR a work-in-progress if the author provides a prefix to their pull request title to the same effect.
pod-utils/decorate
Package decorate is a library for adding to a user-provided PodSpec in order to create a full Pod that will fulfill a test job
Package decorate is a library for adding to a user-provided PodSpec in order to create a full Pod that will fulfill a test job
pod-utils/downwardapi
Package downwardapi declares the types used to expose job configuration to the jobs themselves
Package downwardapi declares the types used to expose job configuration to the jobs themselves
pod-utils/gcs
Package gcs handles uploading files and raw data to blob storage and determines where in the GCS bucket data should go given a specific job specification
Package gcs handles uploading files and raw data to blob storage and determines where in the GCS bucket data should go given a specific job specification
pod-utils/options
Package options abstracts the options loading flow for pod utilities
Package options abstracts the options loading flow for pod utilities
pod-utils/wrapper
Package wrapper contains utilities for the processes that wrap the test execution in a ProwJob test container
Package wrapper contains utilities for the processes that wrap the test execution in a ProwJob test container
secretutil
Package secretutil implements utilities to operate on secret data.
Package secretutil implements utilities to operate on secret data.
sidecar
Package sidecar is a library that knows how to report on the output of a process that writes its output and exit code to disk
Package sidecar is a library that knows how to report on the output of a process that writes its output and exit code to disk
spyglass
Package spyglass creates views for Prow job artifacts.
Package spyglass creates views for Prow job artifacts.
spyglass/lenses
Package lenses provides interfaces and methods necessary for implementing custom artifact viewers
Package lenses provides interfaces and methods necessary for implementing custom artifact viewers
spyglass/lenses/buildlog
Package buildlog provides a build log viewer for Spyglass
Package buildlog provides a build log viewer for Spyglass
spyglass/lenses/coverage
Package coverage provides a coverage viewer for Spyglass
Package coverage provides a coverage viewer for Spyglass
spyglass/lenses/junit
Package junit provides a junit viewer for Spyglass
Package junit provides a junit viewer for Spyglass
spyglass/lenses/metadata
Package metadata provides a metadata viewer for Spyglass
Package metadata provides a metadata viewer for Spyglass
spyglass/lenses/podinfo
Package podinfo provides a coverage viewer for Spyglass
Package podinfo provides a coverage viewer for Spyglass
statusreconciler
Package statusreconciler ensures that changes to required presubmits do not cause PRs in flight to get stuck in the merge queue
Package statusreconciler ensures that changes to required presubmits do not cause PRs in flight to get stuck in the merge queue
test/integration/cmd/fakegcsserver
fakegcsserver runs the open source GCS emulator from https://github.com/fsouza/fake-gcs-server.
fakegcsserver runs the open source GCS emulator from https://github.com/fsouza/fake-gcs-server.
test/integration/cmd/fakegerritserver
fakegerritserver serves github API for integration tests.
fakegerritserver serves github API for integration tests.
test/integration/cmd/fakeghserver
fakeghserver serves github API for integration tests.
fakeghserver serves github API for integration tests.
test/integration/cmd/fakegitserver
fakegitserver serves Git repositories over HTTP for integration tests.
fakegitserver serves Git repositories over HTTP for integration tests.
test/integration/cmd/fakepubsub
fakepubsub wraps around the official gcloud Pub/Sub emulator.
fakepubsub wraps around the official gcloud Pub/Sub emulator.
tide
Package tide contains a controller for managing a tide pool of PRs.
Package tide contains a controller for managing a tide pool of PRs.
tide/history
Package history provides an append only, size limited log of recent actions that Tide has taken for each subpool.
Package history provides an append only, size limited log of recent actions that Tide has taken for each subpool.
version
version holds variables that identify a Prow binary's name and version
version holds variables that identify a Prow binary's name and version
releng
robots
commenter
Commenter provides a way to --query for issues and append a --comment to matches.
Commenter provides a way to --query for issues and append a --comment to matches.
coverage/diff
Package diff calculates the difference of two coverage lists and produces a collection of individual coverage difference.
Package diff calculates the difference of two coverage lists and produces a collection of individual coverage difference.
coverage/downloader
Package downloader finds and downloads the coverage profile file from the latest healthy build stored in given gcs directory
Package downloader finds and downloads the coverage profile file from the latest healthy build stored in given gcs directory
pr-labeler
PR labeler provides a way to add a missing ok-to-test label on trusted PRs.
PR labeler provides a way to add a missing ok-to-test label on trusted PRs.
testgrid

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL