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

helm version fails #1169

Closed
0x53A opened this issue Jun 18, 2020 · 2 comments · Fixed by #1176
Closed

helm version fails #1169

0x53A opened this issue Jun 18, 2020 · 2 comments · Fixed by #1176
Assignees
Labels
kind/bug Some behavior is incorrect or out of spec
Milestone

Comments

@0x53A
Copy link
Contributor

0x53A commented Jun 18, 2020

After updating from 1.6.0 to 2.3.1 pulumi up now fails with

    Error: Error: Command failed: helm version --short || true
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\helm\v2\helm.ts:238:23
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:249:35
        at Generator.next (<anonymous>)
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:21:71
        at new Promise (<anonymous>)
        at __awaiter (C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:17:12)
        at applyHelperAsync (C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:228:12)
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:182:65
        at runMicrotasks (<anonymous>)
        at processTicksAndRejections (internal/process/task_queues.js:97:5)

if I execute helm version --short || true manually, I get the following output:

Client: v2.14.3+g0e7f3b6
Error: could not find tiller
'true' is not recognized as an internal or external command,
operable program or batch file.

(the || true doesn't really make sense on windows)

throw new pulumi.RunError(e.toString());


Environment

OS: Windows 10 1809 x64
Pulumi version: v2.4.0
Pulumi-kubernetes: 2.3.1
Node: v12.16.1

@0x53A
Copy link
Contributor Author

0x53A commented Jun 18, 2020

The || true doesn't seem to be the issue, I went into C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules@pulumi\kubernetes\helm\v2\helm.js and changed it to let helmVerCmd = `helm version --short`;, but it still failed:

    Error: Error: Command failed: helm version --short
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\helm\v2\helm.ts:238:23
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:249:35
        at Generator.next (<anonymous>)
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:21:71
        at new Promise (<anonymous>)
        at __awaiter (C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:17:12)
        at applyHelperAsync (C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:228:12)
        at C:\Progress\repos\customerdeployments\webapi-k8cluster\node_modules\@pulumi\pulumi\output.js:182:65
        at runMicrotasks (<anonymous>)
        at processTicksAndRejections (internal/process/task_queues.js:97:5)

@0x53A
Copy link
Contributor Author

0x53A commented Jun 18, 2020

I changed it to

                var helmVer;
                try
                {
                    helmVer = child_process_1.execSync(helmVerCmd, {
                        stdio: ['pipe', 'pipe', 'ignore'],
                    }).toString();
                }
                catch (e) {
                    helmVer = e.stdout.toString();
                }
                console.log("###helmver", helmVer);

and now it works:

###helmver Client: v2.14.3+g0e7f3b6

0x53A added a commit to 0x53A/pulumi-kubernetes that referenced this issue Jun 18, 2020
@leezen leezen added the kind/bug Some behavior is incorrect or out of spec label Jun 18, 2020
0x53A added a commit to 0x53A/pulumi-kubernetes that referenced this issue Jun 19, 2020
@jaxxstorm jaxxstorm self-assigned this Jun 22, 2020
@jaxxstorm jaxxstorm modified the milestone: current Jun 22, 2020
@leezen leezen added this to the current milestone Jun 23, 2020
@leezen leezen modified the milestones: current, 0.39 Jul 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Some behavior is incorrect or out of spec
Projects
None yet
3 participants