https://pulumi.com logo
#general
Title
# general
f

full-dress-10026

01/24/2019, 7:15 PM
I'm testing out k8s with Pulumi. I added this to my code:
Copy code
const nginx2 = new k8s.helm.v2.Chart("nginx-reverse-proxy", {
    chart: "bitnami/nginx",
    repo: "stable",
    version: "2.1.2",
    values: {
        vhost: nginxConfStr
    }

}, {providers: {kubernetes: cluster.provider}});
and I receive this error message. I have no idea what this means 😕
Copy code
/home/kenny/compute_software/infrastructure/pulumi-k8s-src/node_modules/got/source/create.js:61
        got.stream = (url, options) => got(url, {...options, stream: true});
                                                 ^^^
    SyntaxError: Unexpected token ...
        at Object.exports.runInThisContext (vm.js:53:16)
        at Module._compile (module.js:513:28)
        at Object.Module._extensions..js (module.js:550:10)
        at Module.load (module.js:458:32)
        at tryModuleLoad (module.js:417:12)
        at Function.Module._load (module.js:409:3)
        at Module.require (module.js:468:17)
        at require (internal/module.js:20:19)
        at Object.<anonymous> (/home/kenny/compute_software/infrastructure/pulumi-k8s-src/node_modules/got/source/index.js:3:16)
        at Module._compile (module.js:541:32)
c

creamy-potato-29402

01/24/2019, 7:17 PM
Uh
That looks like an error in one of the libraries?
what the heck
f

full-dress-10026

01/24/2019, 7:17 PM
I just tried `npm install`'ing again but no updates.
c

creamy-potato-29402

01/24/2019, 7:18 PM
Can you share your node version and package.json?
f

full-dress-10026

01/24/2019, 7:18 PM
Copy code
{
  "name": "aws-ts-eks",
  "devDependencies": {
    "@types/node": "latest"
  },
  "dependencies": {
    "@pulumi/pulumi": "latest",
    "@pulumi/aws-infra": "latest",
    "@pulumi/eks": "latest",
    "@pulumi/kubernetes": "latest"
  }
}
Node 6.2.2
i

incalculable-sundown-82514

01/24/2019, 7:21 PM
It looks like the
got
dependency only supports Node 8 or above - I’m not sure which package brought in that dependency, though.
The object spread operator
...
is too new for Node 6
Copy code
▶ yarn why got
yarn why v1.3.2
warning package.json: No license field
[1/4] 🤔   Why do we have the module "got"...?
[2/4] 🚚   Initialising dependency graph...
warning aws-ts-eks: No license field
[3/4] 🔍   Finding dependency...
[4/4] 🚡   Calculating file sizes...
info This module exists because "@pulumi/kubernetes" depends on it.
info Disk size without dependencies: "140kB"
info Disk size with unique dependencies: "376kB"
info Disk size with transitive dependencies: "648kB"
info Number of shared dependencies: 13
g

gorgeous-egg-16927

01/24/2019, 7:49 PM
@incalculable-sundown-82514 the
got
dependency was to support URLs for k8s manifests rather than having to reference local files. Alex added it fairly recently
c

creamy-potato-29402

01/24/2019, 8:05 PM
@full-dress-10026 did this work?
f

full-dress-10026

01/24/2019, 8:06 PM
Updating to Node 8?
c

creamy-potato-29402

01/24/2019, 8:14 PM
yes.
THat should fix it.
I’m filing a bug to move support to node 6, though, @full-dress-10026 in the mean time
in the mean time this should fix it.
f

full-dress-10026

01/24/2019, 8:18 PM
I assume the rest of Pulumi modules are compatible with Node 8?
c

creamy-potato-29402

01/24/2019, 8:19 PM
They should be.
But we’ll get this fixed ASAP.
👍 1