Skip to content

Commit

Permalink
remove legacy chart (#10545)
Browse files Browse the repository at this point in the history
  • Loading branch information
lgadban authored Jan 29, 2025
1 parent 2a4ff05 commit 35feb11
Show file tree
Hide file tree
Showing 53 changed files with 0 additions and 50,123 deletions.
53 changes: 0 additions & 53 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -527,28 +527,6 @@ envoy-wrapper-distroless-docker: $(ENVOYINIT_OUTPUT_DIR)/envoyinit-linux-$(GOARC
--build-arg BASE_IMAGE=$(GLOO_DISTROLESS_BASE_WITH_UTILS_IMAGE) \
-t $(IMAGE_REGISTRY)/$(ENVOYINIT_IMAGE_REPO):$(VERSION)-distroless

#----------------------------------------------------------------------------------
# Deployment Manifests / Helm
#----------------------------------------------------------------------------------

HELM_SYNC_DIR := $(OUTPUT_DIR)/helm
HELM_DIR := install/helm/gloo

.PHONY: generate-helm-files
generate-helm-files: $(OUTPUT_DIR)/.helm-prepared ## Generates required helm files

HELM_PREPARED_INPUT := $(HELM_DIR)/generate.go $(wildcard $(HELM_DIR)/generate/*.go)
$(OUTPUT_DIR)/.helm-prepared: $(HELM_PREPARED_INPUT)
mkdir -p $(HELM_SYNC_DIR)/charts
IMAGE_REGISTRY=$(IMAGE_REGISTRY) go run $(HELM_DIR)/generate.go --version $(VERSION) --generate-helm-docs
touch $@

.PHONY: package-chart
package-chart: generate-helm-files
mkdir -p $(HELM_SYNC_DIR)/charts
helm package --destination $(HELM_SYNC_DIR)/charts $(HELM_DIR)
helm repo index $(HELM_SYNC_DIR)

#----------------------------------------------------------------------------------
# Release
#----------------------------------------------------------------------------------
Expand Down Expand Up @@ -585,48 +563,24 @@ export VERSION

# controller variable for the "Publish Artifacts" section. Defines which targets exist. Possible Values: NONE, RELEASE, PULL_REQUEST
PUBLISH_CONTEXT ?= NONE
# specify which bucket to upload helm chart to
HELM_BUCKET ?= gs://solo-public-tagged-helm

# define empty publish targets so calls won't fail
.PHONY: publish-docker
.PHONY: publish-docker-retag
.PHONY: publish-glooctl
.PHONY: publish-helm-chart

# don't define Publish Artifacts Targets if we don't have a release context
ifneq (,$(filter $(PUBLISH_CONTEXT),RELEASE PULL_REQUEST))

ifeq (RELEASE, $(PUBLISH_CONTEXT)) # RELEASE contexts have additional make targets
HELM_BUCKET := gs://solo-public-helm
# Re-tag docker images previously pushed to the ORIGINAL_IMAGE_REGISTRY,
# and push them to a secondary repository, defined at IMAGE_REGISTRY
publish-docker-retag: docker-retag docker-push

# publish glooctl
publish-glooctl: build-cli
VERSION=$(VERSION) GO111MODULE=on go run ci/upload_github_release_assets.go false
else
# dry run publish glooctl
publish-glooctl: build-cli
VERSION=$(VERSION) GO111MODULE=on go run ci/upload_github_release_assets.go true
endif # RELEASE exclusive make targets

# Build and push docker images to the defined $(IMAGE_REGISTRY)
publish-docker: docker docker-push

# create a new helm chart and publish it to $(HELM_BUCKET)
publish-helm-chart: generate-helm-files
@echo "Uploading helm chart to $(HELM_BUCKET) with name gloo-$(VERSION).tgz"
until $$(GENERATION=$$(gsutil ls -a $(HELM_BUCKET)/index.yaml | tail -1 | cut -f2 -d '#') && \
gsutil cp -v $(HELM_BUCKET)/index.yaml $(HELM_SYNC_DIR)/index.yaml && \
helm package --destination $(HELM_SYNC_DIR)/charts $(HELM_DIR) >> /dev/null && \
helm repo index $(HELM_SYNC_DIR) --merge $(HELM_SYNC_DIR)/index.yaml && \
gsutil -m rsync $(HELM_SYNC_DIR)/charts $(HELM_BUCKET)/charts && \
gsutil -h x-goog-if-generation-match:"$$GENERATION" cp $(HELM_SYNC_DIR)/index.yaml $(HELM_BUCKET)/index.yaml); do \
echo "Failed to upload new helm index (updated helm index since last download?). Trying again"; \
sleep 2; \
done
endif # Publish Artifact Targets

GORELEASER_ARGS ?= --snapshot --clean
Expand Down Expand Up @@ -835,13 +789,6 @@ kind-list-images: ## List solo-io images in the kind cluster named {CLUSTER_NAME
kind-prune-images: ## Remove images in the kind cluster named {CLUSTER_NAME}
docker exec -ti $(CLUSTER_NAME)-control-plane crictl rmi --prune

.PHONY: build-test-chart
build-test-chart: ## Build the Helm chart and place it in the _test directory
mkdir -p $(TEST_ASSET_DIR)
GO111MODULE=on go run $(HELM_DIR)/generate.go --version $(VERSION)
helm package --destination $(TEST_ASSET_DIR) $(HELM_DIR)
helm repo index $(TEST_ASSET_DIR)

#----------------------------------------------------------------------------------
# Targets for running Kubernetes Gateway API conformance tests
#----------------------------------------------------------------------------------
Expand Down
35 changes: 0 additions & 35 deletions install/helm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,43 +4,8 @@ This directory contains the resources to deploy the project via [Helm](https://h

## Directory Structure

- `gloo`: contains the legacy Gloo chart that will be replaced by the kgateway chart
- `kgateway`: contains the WIP kgateway chart

### /kgateway

The kgateway chart contains the new Kubernetes Gateway API implementation. The RBAC configurations in `templates/rbac.yaml` are generated from the API definitions in `projects/gateway2/api/v1alpha1` using kubebuilder's controller-gen tool.

### /gloo

#### generate.go

This go script takes the `*-template.yaml` files in this directory and performs value substitutions
to generate the following files:

- `Chart.yaml`: contains information about the K8s Gateway chart
- `values.yaml`: default configuration values for the chart

Check the [K8s Gateway docs](https://docs.solo.io/k8s-gateway/latest/installation/)
for a description of the different installation options.

#### /crds
This directory contains the K8s Gateway `CustomResourceDefinitions`. This is the
[required location](https://helm.sh/docs/topics/charts/#custom-resource-definitions-crds) for CRDs in Helm 3 charts.

#### /templates
This directory contains the Helm templates used to generate the K8s Gateway manifests.

## Helm-centric commands for the legacy Gloo chart

Relevant commands to helm, meant to be run from the **root of this repository**

```bash
# VERSION is an optional environment variable. If not specified, a default will be computed
VERSION=$VERSION make generate-helm-files # generate `Chart.yaml` and `values.yaml` files
VERSION=$VERSION make package-chart # package a helm chart to `_output/charts` directory (used for releasing)
VERSION=$VERSION make build-test-chart # package a helm chart to `_test` directory (used for testing)

helm install gloo gloo/gloo # install Gloo Edge using Helm
TEST_PKG=install/test make test # run all tests in this project
```
5 changes: 0 additions & 5 deletions install/helm/gloo/.gitignore

This file was deleted.

33 changes: 0 additions & 33 deletions install/helm/gloo/.helmignore

This file was deleted.

14 changes: 0 additions & 14 deletions install/helm/gloo/Chart-template.yaml

This file was deleted.

10 changes: 0 additions & 10 deletions install/helm/gloo/crds/README.md

This file was deleted.

Loading

0 comments on commit 35feb11

Please sign in to comment.