I had an issue where pulumi up would not work on a...
# kubernetes
s
I had an issue where pulumi up would not work on an eks cluster no matter what I did. so I deleted the cluster and it is being set up again but I was wondering if there were better way to handle pulumi state problems refusing to deploy changes to a cluster, is there something else helpful in those situations? It is not always obvious when this is happens other than objects that used to create successfully just stop and the only way to make new changes to the resources is to delete them and start over again.
s
That doesn’t sound like expected behavior. Do you happen to remember what the error message was, or why Pulumi wouldn’t deploy to the existing EKS cluster?
s
yeah so actually one causes of this was bad tsconfig setting (noemit on error) but it happens regularity with Release I have not been able to find the cause yet.
s
Is this
tsconfig
setting something that Pulumi is setting by default?
s
no it was something I was trying to reduce errors in my code at one point and turned out was just not compiling. I still have to run npm run build to get the TS to compile and I a, not sure why yet. it is possible I am still overdoing it.
Copy code
{
  "extends": "./tsconfig.build.json",
  "compilerOptions": {
    "rootDir": ".",
    "noEmit": false,
    "strict": true,
    "declaration": true,
    "outDir": "dist",
    "target": "es2016",
    "module": "commonjs",
    "moduleResolution": "node",
    "sourceMap": true,
    "experimentalDecorators": true,
    "pretty": true,
    "noFallthroughCasesInSwitch": true,
    "noImplicitReturns": true,
    "types": [
      "node"
    ],
    "lib": [
      "ES2018"
    ],
    "forceConsistentCasingInFileNames": true
  },
  "ts-node": {
    "swc": true
  },
  "include": [
    "."
  ],
  "exclude": [
    "node_modules",
    "dist"
  ],
  "files": [
    "src/index.ts"
  ]
}
build json
Copy code
{
  "compilerOptions": {
    "target": "es2020",
    "module": "commonjs",
    "lib": [
      "esnext"
    ],
    "esModuleInterop": true,
    "declaration": true,
    "declarationMap": true,
    "experimentalDecorators": true,
    "emitDecoratorMetadata": true,
    "sourceMap": true,
    "outDir": "dist",
    "rootDir": "src",
    "strict": true,
    "skipLibCheck": true
  },
  "include": [
    "src"
  ]
}
s
You may want to drop back to Pulumi-default settings for
tsconfig.json
and such to see if that helps. You shouldn’t generally need to run any separate steps to get your Pulumi TypeScript code to compile (other than running
pulumi up
).