mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-05-17 18:25:26 +00:00
Update notes for releasing.
This commit is contained in:
@@ -1,43 +0,0 @@
|
||||
[releases page]: https://github.com/kubernetes-sigs/kustomize/releases
|
||||
[`cloud-build-local`]: https://github.com/GoogleCloudPlatform/cloud-build-local
|
||||
[Google Cloud Build]: https://cloud.google.com/cloud-build
|
||||
|
||||
Scripts and configuration files for publishing a
|
||||
`kustomize` release on the [releases page].
|
||||
|
||||
### Build a release locally
|
||||
|
||||
Install [`cloud-build-local`], then run
|
||||
|
||||
```
|
||||
./build/localbuild.sh
|
||||
```
|
||||
|
||||
to build artifacts under `./dist`.
|
||||
|
||||
### Publish a Release
|
||||
|
||||
Get on an up-to-date master branch:
|
||||
```
|
||||
git checkout master
|
||||
git fetch upstream
|
||||
git rebase upstream/master
|
||||
```
|
||||
|
||||
Define the version (see [semver principles](https://semver.org)), e.g.:
|
||||
```
|
||||
version=v1.0.3
|
||||
```
|
||||
|
||||
Tag the repo:
|
||||
```
|
||||
git tag -a $version -m "$version release"
|
||||
```
|
||||
|
||||
Push the tag upstream:
|
||||
```
|
||||
git push upstream $version
|
||||
```
|
||||
|
||||
The new tag will trigger a job in [Google Cloud
|
||||
Build] to put a new release on the [releases page].
|
||||
@@ -1,13 +1,15 @@
|
||||
[release page]: https://github.com/kubernetes-sigs/kustomize/releases
|
||||
[Go]: https://golang.org
|
||||
|
||||
## Installation
|
||||
# Installation
|
||||
|
||||
For linux, macOs and Windows,
|
||||
download a binary from the
|
||||
[release page].
|
||||
Binaries at various versions for linux, macOs and Windows
|
||||
are available on the [release page].
|
||||
|
||||
Or...
|
||||
|
||||
## Quickly curl the latest
|
||||
|
||||
Or try this command:
|
||||
```
|
||||
opsys=linux # or darwin, or windows
|
||||
curl -s https://api.github.com/repos/kubernetes-sigs/kustomize/releases/latest |\
|
||||
@@ -19,7 +21,9 @@ mv kustomize_*_${opsys}_amd64 kustomize
|
||||
chmod u+x kustomize
|
||||
```
|
||||
|
||||
To install from head with [Go] v1.12 or higher:
|
||||
## Install from the HEAD of master branch
|
||||
|
||||
Requires [Go] v1.12 or higher:
|
||||
|
||||
<!-- @installkustomize @test -->
|
||||
```
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Exec plugin on linux in 60 seconds
|
||||
|
||||
This is a (no reading) 60 second copy/paste guided
|
||||
This is a (no reading allowed!) 60 second copy/paste guided
|
||||
example. Full plugin docs [here](README.md).
|
||||
|
||||
This demo writes and uses a somewhat ridiculous
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Go Plugin Guided Example for Linux
|
||||
|
||||
This is a (no reading) 60 second copy/paste guided
|
||||
This is a (no reading allowed!) 60 second copy/paste guided
|
||||
example. Full plugin docs [here](README.md).
|
||||
|
||||
[SopsEncodedSecrets repository]: https://github.com/monopole/sopsencodedsecrets
|
||||
|
||||
@@ -235,7 +235,7 @@ moment forward.
|
||||
[special]: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#resources
|
||||
[k8s API]: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md
|
||||
[conventions]: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md
|
||||
[release process]: ../build/README.md
|
||||
[release process]: ../releasing/README.md
|
||||
[kustomization]: glossary.md#kustomization
|
||||
[`kind`]: https://github.com/kubernetes/community/blob/master/contributors/devel/api-conventions.md#types-kinds
|
||||
[`apiVersion`]: https://kubernetes.io/docs/concepts/overview/kubernetes-api/#api-versioning
|
||||
|
||||
87
releasing/README.md
Normal file
87
releasing/README.md
Normal file
@@ -0,0 +1,87 @@
|
||||
# Releasing
|
||||
|
||||
[releases page]: https://github.com/kubernetes-sigs/kustomize/releases
|
||||
[`cloud-build-local`]: https://github.com/GoogleCloudPlatform/cloud-build-local
|
||||
[Google Cloud Build]: https://cloud.google.com/cloud-build
|
||||
[semver]: https://semver.org
|
||||
|
||||
Scripts and configuration files for publishing a
|
||||
`kustomize` release on the [releases page].
|
||||
|
||||
## Build a release locally
|
||||
|
||||
Install [`cloud-build-local`], then run
|
||||
|
||||
```
|
||||
./releasing/localbuild.sh
|
||||
```
|
||||
|
||||
to build artifacts under `./dist`.
|
||||
|
||||
## Do a real (cloud) release
|
||||
|
||||
Get on an up-to-date master branch:
|
||||
```
|
||||
git fetch upstream
|
||||
git checkout master
|
||||
git rebase upstream/master
|
||||
```
|
||||
|
||||
### review tags
|
||||
|
||||
```
|
||||
git tag -l
|
||||
git ls-remote --tags upstream
|
||||
```
|
||||
|
||||
### define the new tag
|
||||
|
||||
Define the version per [semver] principlesl it must start with `v`:
|
||||
|
||||
```
|
||||
version=v3.0.0-pre
|
||||
```
|
||||
|
||||
### delete the tag if you wish to replace it upstream
|
||||
|
||||
Local delete:
|
||||
|
||||
```
|
||||
git tag --delete $version
|
||||
```
|
||||
|
||||
Upstream delete:
|
||||
```
|
||||
# Disable push protection:
|
||||
git remote set-url --push upstream git@github.com:kubernetes-sigs/kustomize.git
|
||||
|
||||
# The empty space before the colon effectively means delete the tag.
|
||||
git push upstream :refs/tags/$version
|
||||
|
||||
# Enable push protection:
|
||||
git remote set-url --push upstream no_push
|
||||
```
|
||||
|
||||
Optionally visit the [release page] and delete
|
||||
(what has now become) the _draft_ release for that
|
||||
version.
|
||||
|
||||
### tag locally
|
||||
|
||||
```
|
||||
git tag -a $version -m "Release $version"
|
||||
```
|
||||
|
||||
### trigger the cloud build
|
||||
|
||||
Pushing the tag will trigger a job in [Google Cloud
|
||||
Build] to put a new release on the [releases page].
|
||||
|
||||
```
|
||||
git push upstream $version
|
||||
```
|
||||
|
||||
### Update release notes
|
||||
|
||||
Visit the [release page] and edit the release notes as desired.
|
||||
|
||||
@@ -54,6 +54,6 @@ done
|
||||
|
||||
/goreleaser \
|
||||
release \
|
||||
--config=build/goreleaser.yaml \
|
||||
--config=releasing/goreleaser.yaml \
|
||||
--rm-dist \
|
||||
--skip-validate ${SNAPSHOT}
|
||||
@@ -2,7 +2,7 @@ steps:
|
||||
- name: "gcr.io/cloud-builders/git"
|
||||
args: [fetch, --tags, --depth=100]
|
||||
- name: "gcr.io/kubebuilder/goreleaser_with_go_1.12.5:0.0.1"
|
||||
args: ["bash", "build/cloudbuild.sh"]
|
||||
args: ["bash", "releasing/cloudbuild.sh"]
|
||||
secretEnv: ['GITHUB_TOKEN']
|
||||
secrets:
|
||||
- kmsKeyName: projects/kustomize-199618/locations/global/keyRings/github-tokens/cryptoKeys/gh-release-token
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
# Usage
|
||||
#
|
||||
# ./build/localbuild.sh
|
||||
# ./releasing/localbuild.sh
|
||||
#
|
||||
# The script attempts to use cloudbuild configuration
|
||||
# to create a release "locally".
|
||||
@@ -17,11 +17,11 @@
|
||||
# applied to the kustomize repo, the cloud builder
|
||||
# reads the repository-relative file
|
||||
#
|
||||
# build/cloudbuild.yaml
|
||||
# releasing/cloudbuild.yaml
|
||||
#
|
||||
# Inside this yaml file is a reference to the script
|
||||
#
|
||||
# build/cloudbuild.sh
|
||||
# releasing/cloudbuild.sh
|
||||
#
|
||||
# The script you are reading now does something
|
||||
# analogous via docker tricks.
|
||||
@@ -44,7 +44,7 @@ config=$(mktemp)
|
||||
cat <<EOF >$config
|
||||
steps:
|
||||
- name: "gcr.io/kubebuilder/goreleaser_with_go_1.12.5:0.0.1"
|
||||
args: ["bash", "build/cloudbuild.sh", "--snapshot"]
|
||||
args: ["bash", "releasing/cloudbuild.sh", "--snapshot"]
|
||||
secretEnv: ['GITHUB_TOKEN']
|
||||
secrets:
|
||||
- kmsKeyName: projects/kustomize-199618/locations/global/keyRings/github-tokens/cryptoKeys/gh-release-token
|
||||
Reference in New Issue
Block a user