Skip to content

Commit

Permalink
Post release: use clone source and update release process (#3408)
Browse files Browse the repository at this point in the history
* Update post release build script

* removed script to update verison in sdks/rust/Cargo.toml
  • Loading branch information
Kalaiselvi84 authored Sep 29, 2023
1 parent 56c87de commit 7080208
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 132 deletions.
4 changes: 2 additions & 2 deletions build/includes/release.mk
Original file line number Diff line number Diff line change
Expand Up @@ -85,5 +85,5 @@ pre-build-release:
# stores artifacts,
# Pushes the current chart version to the helm repository hosted on gcs.
post-build-release:
docker run --rm $(common_mounts) -w $(workdir_path) $(build_tag) \
gcloud builds submit . --substitutions _VERSION=$(base_version) --config=./build/release/post_cloudbuild.yaml $(ARGS)
docker run --rm $(common_mounts) -w $(workdir_path)/build/release $(build_tag) \
gcloud builds submit . --substitutions _VERSION=$(base_version) --config=./post_cloudbuild.yaml $(ARGS)
5 changes: 0 additions & 5 deletions build/includes/website.mk
Original file line number Diff line number Diff line change
Expand Up @@ -133,11 +133,6 @@ site-config-update-version: ensure-build-image
docker run --rm $(common_mounts) --workdir=$(mount_path) $(DOCKER_RUN_ARGS) $(build_tag) \
go run build/scripts/site-config-update-version/main.go

# update release version agones package in sdks/rust/Cargo.toml
sdks-rust-cargo-version-update: ensure-build-image
docker run --rm $(common_mounts) --workdir=$(mount_path) $(DOCKER_RUN_ARGS) $(build_tag) \
go run build/scripts/sdks-rust-cargo-version-update/main.go

# Delete old release version in site/layouts/partials/navbar.html.
update-navbar-version: FILENAME ?= ""
update-navbar-version: ensure-build-image
Expand Down
14 changes: 9 additions & 5 deletions build/release/post_cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,24 @@
# See the License for the specific language governing permissions and
# limitations under the License.
steps:

#
# Clean out the working dir, so we can replace it.
#
- name: ubuntu
script: rm *

#
# Shallow clone of Agones/main branch from the main repository
#
- name: gcr.io/cloud-builders/git
dir: /workspace
id: clone
args:
- clone
- --depth=1
- --branch=main
- https://github.com/googleforgames/agones.git
- .

#
# Restore any caches
Expand All @@ -33,20 +41,17 @@ steps:
- --bucket=gs://$_CACHE_BUCKET
- --key=$_CPP_SDK_BUILD_CACHE_KEY-$( checksum sdks/cpp/cmake/prerequisites.cmake
)
waitFor: ['-']
- name: us-docker.pkg.dev/$PROJECT_ID/ci/restore_cache
id: cpp-sdk-conformance-restore-cache
args:
- --bucket=gs://$_CACHE_BUCKET
- --key=$_CPP_SDK_CONFORMANCE_CACHE_KEY-$( checksum sdks/cpp/cmake/prerequisites.cmake
)
waitFor: ['-']
- name: us-docker.pkg.dev/$PROJECT_ID/ci/restore_cache
id: rust-sdk-build-restore-cache
args:
- --bucket=gs://$_CACHE_BUCKET
- --key=$_RUST_SDK_BUILD_CACHE_KEY-$( checksum test/sdk/rust/Cargo.toml )
waitFor: ['-']

#
# Creates the initial make + docker build platform
Expand All @@ -57,7 +62,6 @@ steps:
- -c
- "echo 'FROM gcr.io/cloud-builders/docker\nRUN apt-get install make\nENTRYPOINT\
\ [\"/usr/bin/make\"]' > Dockerfile.build"
waitFor: ['-']
- name: gcr.io/cloud-builders/docker
id: build-make-docker
args: [build, -f, Dockerfile.build, -t, make-docker, .]
Expand Down
1 change: 1 addition & 0 deletions build/scripts/sdk-update-version/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ func main() {
"sdks/unity/package.json",
"sdks/csharp/sdk/AgonesSDK.nuspec",
"sdks/csharp/sdk/csharp-sdk.csproj",
"sdks/rust/Cargo.toml",
}

for _, filename := range files {
Expand Down
118 changes: 0 additions & 118 deletions build/scripts/sdks-rust-cargo-version-update/main.go

This file was deleted.

3 changes: 1 addition & 2 deletions docs/governance/templates/release_issue.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,8 @@ and copy it into a release issue. Fill in relevant values, found inside {}
- [ ] Paste the announcement blog post to the #users Slack group.
- [ ] Post to the [agonesdev](https://twitter.com/agonesdev) Twitter account.
- [ ] Run `git checkout main`.
- [ ] Run `make sdk-update-version release_stage=after version={version}` file. This command will update the version number in the sdks/install files to {version}+1-dev.
- [ ] Run `make sdks-rust-cargo-version-update`. Commit the changes in a feature branch called `prep/{version}+1`.
- [ ] Run `make sdk-publish-rust`. This command executes `cargo login` for authentication, performs a dry-run publish, and if that succeeds, does the actual publish. Will need [crate's API TOKEN](https://crates.io/settings/tokens) from your crate's account.
- [ ] Run `make sdk-update-version release_stage=after version={version}` file. This command will update the SDKs and install directories files with `{version}+1-dev` and will also set `{version}+1` in `build/Makefile`.
- [ ] Create PR with these changes, and merge them with approval
- [ ] Close this issue. _Congratulations!_ - the release is now complete! :tada: :clap: :smile: :+1:

Expand Down

0 comments on commit 7080208

Please sign in to comment.