pulumi-kubernetes-operator
pulumi-kubernetes-operator copied to clipboard
`npm install` runs all the time
What happened?
I have pulumi-kubernetes-operator managing 4 stacks from 2 TypeScript programs (fetched from git).
Even if there are no changes to the git repo, the pod keeps continuously running npm install
This does not seem desirable.
Example
All screenshots were taken around the same time.
I have the following dependencies in my package.json in the root of the repo where the pulumi programs reside:
...
"@pulumi/keycloak": "^5.2.1",
"@pulumi/kubernetes": "^4.5.2",
"@pulumi/pulumi": "3.91",
...
Output of pulumi about
Probably not relevant for this case; I'm using version 0.5.0 via the Helm chart.
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).
Thanks for filing the report @v-yarotsky. Have you checked if the issue reproduces on a fresh cluster? It might also be interesting to try to run a manual preview for the stacks to see if there is and to check the interval for the reconcile loop.
After taking a brief look at the code, it seems like this is by design.
On each iteration of the Reconcile loop^1, reconcileStackSession.setupWorkspace^2 is called, which in turn calls reconcileStackSession.InstallProjectDependencies^3. All of that is happening before checking whether the current commit matches the last applied one^4.
Added to epic https://github.com/pulumi/pulumi-kubernetes-operator/issues/586
Good news everyone, we just release a preview of Pulumi Kubernetes Operator v2. This new release has a whole-new architecture that uses pods as the execution environment, and seeks to retain the pod across stack operations. Installation happens once whenever a new commit is observed by the system. It is also now possible to create a custom docker image with your bits pre-installed, to further increase performance.
Please read the announcement blog post for more information: https://www.pulumi.com/blog/pulumi-kubernetes-operator-2-0/
Would love to hear your feedback! Feel free to engage with us on the #kubernetes channel of the Pulumi Slack workspace. cc @v-yarotsky @rodolfototaro @ainthapanya-sqc
Cannot close issue:
- does not have an assignee
Please fix these problems and try again.