You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by lh...@apache.org on 2024/01/17 16:19:37 UTC
(pulsar-helm-chart) 01/02: Fix creating namespace for cert-manager deployment
This is an automated email from the ASF dual-hosted git repository.
lhotari pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar-helm-chart.git
commit 23211c998ab993285353519453010dcb15f64864
Author: Lari Hotari <lh...@apache.org>
AuthorDate: Wed Jan 17 17:50:38 2024 +0200
Fix creating namespace for cert-manager deployment
---
scripts/cert-manager/install-cert-manager.sh | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/scripts/cert-manager/install-cert-manager.sh b/scripts/cert-manager/install-cert-manager.sh
index 403902e..4cbecf9 100755
--- a/scripts/cert-manager/install-cert-manager.sh
+++ b/scripts/cert-manager/install-cert-manager.sh
@@ -31,16 +31,6 @@ VERSION=v1.11.4
echo "Installing cert-manager CRD resources ..."
kubectl apply --validate=false -f https://github.com/jetstack/cert-manager/releases/download/${VERSION}/cert-manager.crds.yaml
-# Create the namespace
-kubectl get ns ${NAMESPACE}
-if [ $? == 0 ]; then
- echo "Namespace '${NAMESPACE}' already exists."
-else
- echo "Creating namespace '${NAMESPACE}' ..."
- kubectl create namespace ${NAMESPACE}
- echo "Successfully created namespace '${NAMESPACE}'."
-fi
-
# Add the Jetstack Helm repository.
echo "Adding Jetstack Helm repository."
helm repo add jetstack https://charts.jetstack.io
@@ -53,6 +43,7 @@ helm repo update
echo "Installing cert-manager ${VERSION} to namespace ${NAMESPACE} as '${NAME}' ..."
helm install \
--namespace ${NAMESPACE} \
+ --create-namespace \
--version ${VERSION} \
${NAME} \
jetstack/cert-manager