-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2409 from camilamacedo86/release-3
- Loading branch information
Showing
431 changed files
with
8,586 additions
and
3,614 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: APIDiff | ||
|
||
# Trigger the workflow on pull requests and direct pushes to any branch | ||
on: | ||
push: | ||
pull_request: | ||
|
||
jobs: | ||
go-apidiff: | ||
name: Verify API differences | ||
runs-on: ubuntu-latest | ||
# Pull requests from different repository only trigger this checks | ||
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository | ||
steps: | ||
- name: Clone the code | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Setup Go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: '1.16' | ||
- name: Execute go-apidiff | ||
uses: joelanford/[email protected] | ||
with: | ||
compare-imports: true | ||
print-compatible: true | ||
- name: Report failure | ||
uses: nashmaniac/[email protected] | ||
# Only report failures of pushes (PRs have are visible through the Checks section) to the default branch | ||
if: failure() && github.event_name == 'push' && github.ref == 'refs/heads/master' | ||
with: | ||
title: 🐛 go-apidiff failed for ${{ github.sha }} | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
labels: kind/bug | ||
body: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,7 +18,7 @@ jobs: | |
- name: Run linter | ||
uses: golangci/golangci-lint-action@v2 | ||
with: | ||
version: v1.37 # Always uses the latest patch version. | ||
version: v1.41 # Always uses the latest patch version. | ||
only-new-issues: true # Show only new issues if it's a pull request | ||
- name: Report failure | ||
uses: nashmaniac/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ Please see https://git.k8s.io/community/CLA.md for more info. | |
|
||
## Prerequisites | ||
|
||
- [go](https://golang.org/dl/) version v1.15+. | ||
- [go](https://golang.org/dl/) version v1.16+. | ||
- [docker](https://docs.docker.com/install/) version 17.03+. | ||
- [kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl/) version v1.11.3+. | ||
- [kustomize](https://sigs.k8s.io/kustomize/docs/INSTALL.md) v3.1.0+ | ||
|
@@ -35,13 +35,15 @@ $ git clone [email protected]:<user>/kubebuilder.git $GOPATH/src/sigs.k8s.io/kubebu | |
``` | ||
|
||
1. Ensure you activate module support before continue (`$ export GO111MODULE=on`) | ||
1. Run the command `make install` to create a bin with the source code | ||
1. Run the command `make install` to create a bin with the source code | ||
|
||
**NOTE** In order to check the local environment run `make test-unit`. | ||
|
||
## What to do before submitting a pull request | ||
## What to do before submitting a pull request | ||
|
||
1. Run the script `make generate` to update/generate the mock data used in the e2e test in `$GOPATH/src/sigs.k8s.io/kubebuilder/testdata/` | ||
1. Run the script `make generate` to update/generate the mock data used in the e2e test in `$GOPATH/src/sigs.k8s.io/kubebuilder/testdata/` | ||
1. Run `make test-unit test-e2e-local` | ||
- e2e tests use [`kind`][kind] and [`setup-envtest`][setup-envtest]. If you want to bring your own binaries, place them in `$(go env GOPATH)/bin`. | ||
|
||
**IMPORTANT:** The `make generate` is very helpful. By using it, you can check if good part of the commands still working successfully after the changes. Also, note that its usage is a pre-requirement to submit a PR. | ||
|
||
|
@@ -87,9 +89,9 @@ separately. | |
|
||
## Where the CI Tests are configured | ||
|
||
1. See the [action files](.github/workflows) to check its tests, and the scripts used on it. | ||
1. Note that the prow tests used in the CI are configured in [kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml](https://github.com/kubernetes/test-infra/blob/master/config/jobs/kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml). | ||
1. Check that all scripts used by the CI are defined in the project. | ||
1. See the [action files](.github/workflows) to check its tests, and the scripts used on it. | ||
1. Note that the prow tests used in the CI are configured in [kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml](https://github.com/kubernetes/test-infra/blob/master/config/jobs/kubernetes-sigs/kubebuilder/kubebuilder-presubmits.yaml). | ||
1. Check that all scripts used by the CI are defined in the project. | ||
|
||
## How to contribute to docs | ||
|
||
|
@@ -102,7 +104,7 @@ The docs are published off of three branches: | |
legacy docs | ||
- `master`: | ||
[master.book.kubebuilder.io](https://master.book.kubebuilder.io) -- | ||
"nightly" docs | ||
"nightly" docs | ||
|
||
See [VERSIONING.md](VERSIONING.md#book-releases) for more information. | ||
|
||
|
@@ -129,3 +131,5 @@ KubeBuilder and the related repositories. See | |
Participation in the Kubernetes community is governed by the [Kubernetes Code of Conduct](code-of-conduct.md). | ||
|
||
[golangci]:https://github.com/golangci/golangci-lint | ||
[kind]:https://kind.sigs.k8s.io/#installation-and-usage | ||
[setup-envtest]:https://book.kubebuilder.io/reference/envtest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.