Skip to content

Commit d5444f5

Browse files
committed
Simplify installation method in kubectl-rabbitmq
1 parent 6a8a87e commit d5444f5

File tree

1 file changed

+1
-23
lines changed

1 file changed

+1
-23
lines changed

bin/kubectl-rabbitmq

+1-23
Original file line numberDiff line numberDiff line change
@@ -188,29 +188,7 @@ secrets() {
188188
}
189189

190190
install_cluster_operator() {
191-
cd "$(mktemp -d)" || exit 1
192-
which -s git || {
193-
echo "Please install git and try again"
194-
exit 1
195-
}
196-
git clone https://github.com/rabbitmq/cluster-operator.git 2>/dev/null|| {
197-
echo "Failed to clone the repository."
198-
exit 1
199-
}
200-
(
201-
cd cluster-operator || exit 1
202-
if [[ -n "${1}" ]]; then
203-
echo "Setting operator image to ${1}"
204-
(
205-
cd config/manager || exit 1
206-
kustomize edit set image "controller=${1}"
207-
)
208-
fi
209-
kubectl apply -f config/namespace/base/namespace.yaml
210-
kubectl apply -f config/crd/bases/rabbitmq.com_rabbitmqclusters.yaml
211-
kubectl -n rabbitmq-system apply --kustomize config/rbac/
212-
kubectl -n rabbitmq-system apply --kustomize config/manager/
213-
)
191+
kubectl apply -f https://github.com/rabbitmq/cluster-operator/releases/latest/download/cluster-operator.yml
214192
}
215193

216194
main() {

0 commit comments

Comments
 (0)