Skip to content

Helm hooks not being processed in correct order #2995

Closed

Description

@lachie83

I'm having issues ordering the creation of the following resource in this PR - helm/charts#2369.

I have a bunch of CRD pre-install resources with a weight of 1 and a bunch of custom resources with a hook weight of 2. I expect the resource with a weight of 1 to be installed first. Instead I see the behaviour works some of the time and other times results in

$ helm install --name istio . --namespace istio-system
Error: apiVersion "config.istio.io/v1alpha2" in istio/templates/custom-resources.yaml is not available

This is helm 2.6.1 on k8s 1.7.5

Activity

  1. changed the title [-]Helm hooks not being processed [/-] [+]Helm hooks not being processed in correct order[/+] on Oct 2, 2017
  2. lachie83 commented on Oct 2, 2017

    @lachie83
    ContributorAuthor

    Seeing the following in tiller logs

    [tiller] 2017/10/02 07:47:40 preparing install for istio
    [storage] 2017/10/02 07:47:40 getting release history for "istio"
    [tiller] 2017/10/02 07:47:40 rendering istio chart using values
    [tiller] 2017/10/02 07:47:40 failed install prepare step: apiVersion "config.istio.io/v1alpha2" in istio/templates/custom-resources.yaml is not available
    
  3. bacongobbler commented on Oct 2, 2017

    @bacongobbler
    Member

    The proper annotation is actually helm.sh/hookWeight, not helm.sh/hook-weight. Your hooks don't have a weight assigned to them :)

    Perhaps this is something we should capture in helm lint as I've seen this occur more than once.

  4. bacongobbler commented on Oct 2, 2017

    @bacongobbler
    Member
  5. unguiculus commented on Oct 2, 2017

    @unguiculus
    Member

    helm.sh/hook-weight is correct. The mentioned commit above is the original one in the PR. It was changed by my review.

    #2157 (comment)

    https://github.com/kubernetes/helm/blob/master/pkg/hooks/hooks.go#L27

  6. bacongobbler commented on Oct 2, 2017

    @bacongobbler
    Member
  7. fejta-bot commented on Jan 6, 2018

    @fejta-bot

    Issues go stale after 90d of inactivity.
    Mark the issue as fresh with /remove-lifecycle stale.
    Stale issues rot after an additional 30d of inactivity and eventually close.

    Prevent issues from auto-closing with an /lifecycle frozen comment.

    If this issue is safe to close now please do so with /close.

    Send feedback to sig-testing, kubernetes/test-infra and/or @fejta.
    /lifecycle stale

  8. fejta-bot commented on Feb 10, 2018

    @fejta-bot

    Stale issues rot after 30d of inactivity.
    Mark the issue as fresh with /remove-lifecycle rotten.
    Rotten issues close after an additional 30d of inactivity.

    If this issue is safe to close now please do so with /close.

    Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
    /lifecycle rotten
    /remove-lifecycle stale

  9. fejta-bot commented on Mar 12, 2018

    @fejta-bot

    Rotten issues close after 30d of inactivity.
    Reopen the issue with /reopen.
    Mark the issue as fresh with /remove-lifecycle rotten.

    Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
    /close

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions