Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing the helm chart without the --wait parameter fails #406

Open
zioproto opened this issue Jan 23, 2024 · 3 comments
Open

Installing the helm chart without the --wait parameter fails #406

zioproto opened this issue Jan 23, 2024 · 3 comments
Labels
kind/bug Categorizes issue or PR as related to a bug. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one.

Comments

@zioproto
Copy link
Contributor

What steps did you take and what happened:

minikube delete
minikube start
helm repo add jetstack https://charts.jetstack.io
helm repo add cluster-api-operator https://kubernetes-sigs.github.io/cluster-api-operator
helm repo update
helm upgrade cert-manager jetstack/cert-manager \
    --install \
    --create-namespace \
    --wait \
    --namespace cert-manager \
    --set installCRDs=true

helm install capi cluster-api-operator/cluster-api-operator \
    --set infrastructure=azure \
    --set addon=helm \
    --set image.manager.tag=v0.8.1 \
    --debug

Fails with the following output

Error: INSTALLATION FAILED: failed post-install: warning: Hook post-install cluster-api-operator/templates/infra.yaml failed: 1 error occurred:
	* Internal error occurred: failed calling webhook "vinfrastructureprovider.kb.io": failed to call webhook: Post "https://capi-operator-webhook-service.default.svc:443/mutate-operator-cluster-x-k8s-io-v1alpha2-infrastructureprovider?timeout=10s": dial tcp 10.103.91.243:443: connect: connection refused


helm.go:84: [debug] failed post-install: warning: Hook post-install cluster-api-operator/templates/infra.yaml failed: 1 error occurred:
	* Internal error occurred: failed calling webhook "vinfrastructureprovider.kb.io": failed to call webhook: Post "https://capi-operator-webhook-service.default.svc:443/mutate-operator-cluster-x-k8s-io-v1alpha2-infrastructureprovider?timeout=10s": dial tcp 10.103.91.243:443: connect: connection refused


INSTALLATION FAILED
main.newInstallCmd.func2
	helm.sh/helm/v3/cmd/helm/install.go:154
github.com/spf13/cobra.(*Command).execute
	github.com/spf13/[email protected]/command.go:983
github.com/spf13/cobra.(*Command).ExecuteC
	github.com/spf13/[email protected]/command.go:1115
github.com/spf13/cobra.(*Command).Execute
	github.com/spf13/[email protected]/command.go:1039
main.main
	helm.sh/helm/v3/cmd/helm/helm.go:83
runtime.main
	runtime/proc.go:267
runtime.goexit
	runtime/asm_arm64.s:1197

What did you expect to happen:
I expected the helm chart to install successfully

Anything else you would like to add:

If you add the --wait parameter it works

helm uninstall capi
helm install capi cluster-api-operator/cluster-api-operator \
    --set infrastructure=azure \
    --set addon=helm \
    --set image.manager.tag=v0.8.1 \
    --debug \
    --wait

Environment:

  • Cluster-api-operator version: v0.8.1
  • Cluster-api version:
  • Minikube/KIND version: v1.32.0
  • Kubernetes version: (use kubectl version): v1.28.3
  • OS (e.g. from /etc/os-release):

/kind bug
[One or more /area label. See https://github.com/kubernetes-sigs/cluster-api-operator/labels?q=area for the list of labels]

@k8s-ci-robot k8s-ci-robot added kind/bug Categorizes issue or PR as related to a bug. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jan 23, 2024
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If CAPI Operator contributors determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@alexander-demicev
Copy link
Contributor

alexander-demicev commented Mar 13, 2024

I'm not sure that we can fix this, controllers need to start for webhooks to work. Only after controller is up operator CRs can be applied.

@mxmxchere
Copy link

mxmxchere commented May 16, 2024

Not the cleanest of all approaches but we could create a Job with a check (e.g. curl) if the webhook works yet. If so the Job terminates. The job than has to be installed with a post-install weight that is lower than the one that failed.


In case a desperate flux user is reading this: hr.spec.persistentClient=false seems to do the trick if you have the same issue when trying to deploy via flux helmreleasecontroller.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one.
Projects
None yet
Development

No branches or pull requests

4 participants