Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix(exp-engine): use updated Helm API
Signed-off-by: Ilya Lesikov <ilya@lesikov.com>
  • Loading branch information
ilya-lesikov committed Jul 24, 2023
1 parent c09deb0 commit e6c8c1a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions cmd/werf/converge/converge.go
Expand Up @@ -564,7 +564,7 @@ func run(ctx context.Context, containerBackend container_backend.ContainerBacken

statusProgressPeriod := time.Duration(*commonCmdData.StatusProgressPeriodSeconds) * time.Second
hooksStatusProgressPeriod := time.Duration(*commonCmdData.HooksStatusProgressPeriodSeconds) * time.Second
tracker := resourcetracker.NewResourceTracker(statusProgressPeriod, hooksStatusProgressPeriod)
tracker := resourcetracker.NewResourceTracker(deferredKubeClient.Static(), deferredKubeClient.Dynamic(), deferredKubeClient.Discovery(), deferredKubeClient.Mapper(), resourcetracker.NewResourceTrackerOptions{Logger: logger})

cli, err := client.NewClient(deferredKubeClient.Static(), deferredKubeClient.Dynamic(), deferredKubeClient.Discovery(), deferredKubeClient.Mapper(), waiter)
if err != nil {
Expand Down Expand Up @@ -860,7 +860,7 @@ func run(ctx context.Context, containerBackend container_backend.ContainerBacken
}()
}

deployReport, executeErr := plan.NewDeployPlanExecutor(deployPlan, releaseNamespace, cli, tracker, actionConfig.Releases).WithTrackTimeout(trackTimeout).Execute(ctx)
deployReport, executeErr := plan.NewDeployPlanExecutor(deployPlan, releaseNamespace, cli, tracker, actionConfig.Releases).WithTrackTimeout(trackTimeout).WithResourceShowProgressPeriod(statusProgressPeriod).WithHookShowProgressPeriod(hooksStatusProgressPeriod).Execute(ctx)
if executeErr != nil {
defer func() {
fmt.Fprintf(errStream, "\nRelease %q in namespace %q failed.\n", releaseName, releaseNamespace)
Expand All @@ -874,7 +874,7 @@ func run(ctx context.Context, containerBackend container_backend.ContainerBacken
Build()

// FIXME(ilya-lesikov): deploy report from this execute is not used
_, err = plan.NewDeployPlanExecutor(finalizeFailedDeployPlan, releaseNamespace, cli, tracker, actionConfig.Releases).WithTrackTimeout(trackTimeout).WithReport(deployReport).Execute(ctx)
_, err = plan.NewDeployPlanExecutor(finalizeFailedDeployPlan, releaseNamespace, cli, tracker, actionConfig.Releases).WithTrackTimeout(trackTimeout).WithResourceShowProgressPeriod(statusProgressPeriod).WithHookShowProgressPeriod(hooksStatusProgressPeriod).WithReport(deployReport).Execute(ctx)
if err != nil {
return multierror.Append(executeErr, fmt.Errorf("error finalizing failed deploy plan: %w", err))
}
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Expand Up @@ -347,6 +347,6 @@ replace (
github.com/helm/helm-2to3 => github.com/werf/3p-helm-2to3 v0.0.0-20230313155428-cf9dd655c0e3 // switch back to upstream when merged: https://github.com/helm/helm-2to3/pull/224
github.com/jaguilar/vt100 => github.com/tonistiigi/vt100 v0.0.0-20190402012908-ad4c4a574305 // upstream not maintained
github.com/maorfr/helm-plugin-utils => github.com/werf/3p-helm-plugin-utils v0.6.1-0.20230313152239-057595ce9d57 // switch back to upstream when merged: https://github.com/maorfr/helm-plugin-utils/pull/17
helm.sh/helm/v3 => github.com/werf/3p-helm/v3 v3.0.0-20230721125930-595aa78112f5
helm.sh/helm/v3 => github.com/werf/3p-helm/v3 v3.0.0-20230724143857-81fee9872ef8
k8s.io/helm => github.com/werf/helm v0.0.0-20210202111118-81e74d46da0f
)
4 changes: 2 additions & 2 deletions go.sum
Expand Up @@ -1740,8 +1740,8 @@ github.com/weppos/publicsuffix-go v0.5.0/go.mod h1:z3LCPQ38eedDQSwmsSRW4Y7t2L8Ln
github.com/weppos/publicsuffix-go v0.20.1-0.20221209102050-40d9c30084b3 h1:ypyhoprZWFzU0ydOBv3I5SS7/jLFJ+ujPAU+BD/EVFM=
github.com/werf/3p-helm-2to3 v0.0.0-20230313155428-cf9dd655c0e3 h1:pdKLiuiUoOFswc0HV6GX1+JHgP14HqE035xl2DQJi8A=
github.com/werf/3p-helm-2to3 v0.0.0-20230313155428-cf9dd655c0e3/go.mod h1:lTSQBLomjl67m4HQMbg3BHKWes3pOmjNBg8yygXYugk=
github.com/werf/3p-helm/v3 v3.0.0-20230721125930-595aa78112f5 h1:ABh2GLSHga60eCodqBlLPzy46qMFX3u3wNlUP7vIHbk=
github.com/werf/3p-helm/v3 v3.0.0-20230721125930-595aa78112f5/go.mod h1:vH6ckglZT6mhJefVLbUM9759Zt/wQnqqRe0BY4jmmHM=
github.com/werf/3p-helm/v3 v3.0.0-20230724143857-81fee9872ef8 h1:EapJbxzmXXZduzj0D2YIepcUGwAbOzDJGHsH5ReUYIk=
github.com/werf/3p-helm/v3 v3.0.0-20230724143857-81fee9872ef8/go.mod h1:vH6ckglZT6mhJefVLbUM9759Zt/wQnqqRe0BY4jmmHM=
github.com/werf/copy-recurse v0.2.7 h1:3FTOarbJ9uhFLi75oeUCioK9zxZwuV7o28kuUBPDZPM=
github.com/werf/copy-recurse v0.2.7/go.mod h1:6Ypb+qN+hRBJgoCgEkX1vpbqcQ+8q69BQ3hi8s8Y6Qc=
github.com/werf/helm v0.0.0-20210202111118-81e74d46da0f h1:81YscYTF9mmTf0ULOsCmm42YWQp+qWDzWi1HjWniZrg=
Expand Down

0 comments on commit e6c8c1a

Please sign in to comment.