https://pulumi.com logo
#kubernetes
Title
# kubernetes
i

icy-jordan-58549

05/31/2021, 2:34 PM
any ideas why I am getting this error?
Copy code
error: no resource plugin 'kubernetes-v1.1.0' found in the workspace or on your $PATH, install the plugin using `pulumi plugin install resource kubernetes v1.1.0`
I thought this is installed by cli automatically
b

billowy-army-68599

06/01/2021, 3:24 PM
hey, sorry for the delay here - this is generally becayse you have this version inside your state, but your language deps differ - you'll have to install this manually. if you update your package deps it may get pulled in too
i

icy-jordan-58549

06/04/2021, 9:28 AM
thanks @billowy-army-68599
@billowy-army-68599 the issue here was inside crd2pulumi code
the fix
Copy code
export function getVersion(): string {
    let version = require('../package.json').dependencies['@pulumi/kubernetes'];
    // Node allows for the version to be prefixed by a "v", while semver doesn't.
    // If there is a v, strip it off.
    if (version.indexOf('v') === 0) {
        version = version.slice(1);
    }
    return version;
}
not sure why, but by taking version out from my package.json, it does use the same version for kuberentes plugin
let version = require('../package.json').dependencies['@pulumi/kubernetes'];
by doing this, I force it to use the version from installed dependency
does it make sense?
not sure if this is something interesting for github discussion Q/A @broad-dog-22463
5 Views