Skip to content

Commit

Permalink
helm manifests template based
Browse files Browse the repository at this point in the history
Signed-off-by: Eguzki Astiz Lezaun <eastizle@redhat.com>
  • Loading branch information
eguzki committed Oct 3, 2024
1 parent 460ac26 commit d789ab9
Show file tree
Hide file tree
Showing 9 changed files with 479 additions and 474 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -166,3 +166,17 @@ jobs:
- name: Verify generate command
run: |
make verify-go-mod
verify-helm-charts:
name: Verify helm charts
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.22.x
uses: actions/setup-go@v4
with:
go-version: 1.22.x
id: go
- name: Check out code
uses: actions/checkout@v4
- name: Run make verify-helm-charts
run: |
make verify-helm-charts
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified

deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in ~/.kube/config.
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG}
$(KUSTOMIZE) build config/default | kubectl apply -f -
$(KUSTOMIZE) build config/deploy | kubectl apply -f -
cd config/manager && $(KUSTOMIZE) edit set image controller=${DEFAULT_IMG}

deploy-develmode: manifests kustomize ## Deploy controller in debug mode to the K8s cluster specified in ~/.kube/config.
Expand All @@ -300,7 +300,7 @@ deploy-develmode: manifests kustomize ## Deploy controller in debug mode to the
cd config/manager && $(KUSTOMIZE) edit set image controller=${DEFAULT_IMG}

undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/config.
$(KUSTOMIZE) build config/default | kubectl delete -f -
$(KUSTOMIZE) build config/deploy | kubectl delete -f -

.PHONY: install-olm
install-olm: $(OPERATOR_SDK)
Expand Down
902 changes: 437 additions & 465 deletions charts/limitador-operator/templates/manifests.yaml

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion config/deploy-develmode/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ../default
- ../deploy
patchesStrategicMerge:
- devel_mode_patch.yaml
7 changes: 7 additions & 0 deletions config/deploy/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: limitador-operator-system
resources:
- namespace.yaml
- ../default
7 changes: 7 additions & 0 deletions config/deploy/namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
apiVersion: v1
kind: Namespace
metadata:
labels:
control-plane: controller-manager
name: system
4 changes: 4 additions & 0 deletions config/helm/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: "{{ .Release.Namespace }}"
resources:
- ../default
6 changes: 0 additions & 6 deletions config/manager/manager.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
apiVersion: v1
kind: Namespace
metadata:
labels:
control-plane: controller-manager
name: system
---
apiVersion: apps/v1
kind: Deployment
Expand Down
5 changes: 5 additions & 0 deletions make/verify.mk
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,8 @@ verify-generate: generate ## Verify generate update.
verify-go-mod: ## Verify go.mod matches source code
go mod tidy
git diff --exit-code ./go.mod

.PHONY: verify-helm-charts
verify-helm-charts: helm-build ## Verify helm charts update.
git diff --exit-code ./charts
[ -z "$$(git ls-files --other --exclude-standard --directory --no-empty-directory ./charts)" ]

0 comments on commit d789ab9

Please sign in to comment.