Skip to content
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

Update do-release to fully build images #675

Merged
merged 1 commit into from
Mar 27, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 9 additions & 14 deletions build/includes/release.mk
Original file line number Diff line number Diff line change
Expand Up @@ -45,28 +45,23 @@ gen-changelog:
do-release: RELEASE_VERSION ?= $(base_version)
do-release:
@echo "Starting release for version: $(RELEASE_VERSION)"

# switch to the right project
$(DOCKER_RUN) gcloud config configurations activate agones-images

git checkout -b release-$(RELEASE_VERSION)
$(MAKE) lint test FULL_BUILD=1
-rm -rf $(agones_path)/release
mkdir $(agones_path)/release
docker run --rm $(common_mounts) -w $(mount_path)/sdks/cpp $(build_tag) make clean
$(MAKE) build-sdks build-agones-sdk-binary VERSION=$(RELEASE_VERSION) REGISTRY=$(release_registry) FULL_BUILD=1

$(MAKE) -j 4 build VERSION=$(RELEASE_VERSION) REGISTRY=$(release_registry) FULL_BUILD=1
cp $(agones_path)/cmd/sdk-server/bin/agonessdk-server-$(RELEASE_VERSION).zip $(agones_path)/release
cp $(agones_path)/sdks/cpp/bin/agonessdk-$(RELEASE_VERSION)-runtime-linux-arch_64.tar.gz $(agones_path)/release
cp $(agones_path)/sdks/cpp/bin/agonessdk-$(RELEASE_VERSION)-dev-linux-arch_64.tar.gz $(agones_path)/release
cp $(agones_path)/sdks/cpp/bin/agonessdk-$(RELEASE_VERSION)-src.zip $(agones_path)/release
cp $(agones_path)/sdks/cpp/.build/agonessdk-$(RELEASE_VERSION)-linux-arch_64.tar.gz $(agones_path)/release
cd $(agones_path) && zip -r ./release/agones-install-$(RELEASE_VERSION).zip ./README.md ./install ./LICENSE

# retag the current master commit images with the release tag.
$(MAKE) do-relase-tag-images RELEASE_VERSION=$(RELEASE_VERSION)
$(MAKE) gcloud-auth-docker
$(MAKE) -j 3 push REGISTRY=$(release_registry) VERSION=$(RELEASE_VERSION)

$(MAKE) push-chart VERSION=$(RELEASE_VERSION)
git push -u upstream release-$(RELEASE_VERSION)

@echo "Now go make the $(RELEASE_VERSION) release on Github!"

do-relase-tag-images: RELEASE_VERSION ?= $(base_version)
do-relase-tag-images:
docker run --rm $(common_mounts) $(build_tag) gcloud container images add-tag $(release_registry)/agones-controller:$(VERSION) $(release_registry)/agones-controller:$(RELEASE_VERSION) --quiet
docker run --rm $(common_mounts) $(build_tag) gcloud container images add-tag $(release_registry)/agones-sdk:$(VERSION) $(release_registry)/agones-sdk:$(RELEASE_VERSION) --quiet
docker run --rm $(common_mounts) $(build_tag) gcloud container images add-tag $(release_registry)/agones-ping:$(VERSION) $(release_registry)/agones-ping:$(RELEASE_VERSION) --quiet