chore(samples): improvements of sample Makefiles for MySQL and PostgreSQL datastores (#1234)

* fix(docs): update command to collect the external IP address of the TCP service

* chore(samples): improvements of sample Makefiles for MySQL and PostgreSQL datastores
This commit is contained in:
Antonio B.
2026-07-11 09:48:11 +02:00
committed by GitHub
parent b99609a435
commit 99cea553c8
2 changed files with 9 additions and 3 deletions
+3 -1
View File
@@ -31,4 +31,6 @@ mariadb-deployment:
mariadb-destroy:
@NAME=$(NAME) envsubst < $(ROOT_DIR)/mariadb.yaml | kubectl -n $(NAMESPACE) delete --ignore-not-found -f -
@kubectl delete -n $(NAMESPACE) secret mysql-$(NAME)config --ignore-not-found
@kubectl delete -n $(NAMESPACE) secret mysql-$(NAME)-config --ignore-not-found
@kubectl delete namespace $(NAMESPACE) --ignore-not-found
@rm -rf $(ROOT_DIR)/certs/$(NAME)
+6 -2
View File
@@ -1,6 +1,6 @@
ROOT_DIR:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
NAME:=default
NAMESPACE:=kamaji-system
NAMESPACE:=postgres-system
postgresql: cnpg-setup cnpg-deploy postgresql-secret
@@ -25,5 +25,9 @@ postgresql-secret: cnpg
--cnpg-user $$(kubectl -n $(NAMESPACE) get secret postgres-$(NAME)-superuser -o jsonpath='{.data.username}' | base64 -d)
postgresql-destroy:
@NAME=$(NAME) envsubst < postgresql.yaml | kubectl -n $(NAMESPACE) delete -f -
@NAME=$(NAME) envsubst < postgresql.yaml | kubectl -n $(NAMESPACE) delete --ignore-not-found -f -
@kubectl -n $(NAMESPACE) delete secret postgres-$(NAME)-root-cert --ignore-not-found
@kubectl -n $(NAMESPACE) delete secret postgres-$(NAME)-superuser --ignore-not-found
@kubectl delete namespace $(NAMESPACE) --ignore-not-found
@kubectl delete -f https://raw.githubusercontent.com/cloudnative-pg/cloudnative-pg/main/releases/cnpg-1.18.0.yaml --ignore-not-found
@rm -f $(shell git rev-parse --show-toplevel)/bin/kubectl-cnpg