jx3-gitops-repositories / jx3-kubernetes

Jenkins X 3.x GitOps repository for a vanilla Kubernetes cluster
Apache License 2.0
14 stars 46 forks source link

--prune is in alpha and doesn't currently work on objects created by server-side apply #15

Open willzhang opened 1 year ago

willzhang commented 1 year ago
using kubectl to apply resources
if [ -d config-root/customresourcedefinitions ]; then \
  kubectl apply --server-side=true --force-conflicts --prune -l=gitops.jenkins-x.io/pipeline=customresourcedefinitions -R -f config-root/customresourcedefinitions; \
fi
error: --prune is in alpha and doesn't currently work on objects created by server-side apply
make: *** [versionStream/src/Makefile.mk:322: kubectl-apply] Error 1
# kubectl version --short
Flag --short has been deprecated, and will be removed in the future. The --short output will become the default.
Client Version: v1.27.6
Kustomize Version: v5.0.1
Server Version: v1.27.6