-
Notifications
You must be signed in to change notification settings - Fork 115
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
Give the possibility to set an annotation that forces resource re-creation #1007
Comments
I got the same issue installing prometheus-operator helm chart |
Related to pulumi/pulumi#6753. We could choose whether to address this via a general Pulumi option like in 6753, or a Kubernetes-specific annotation like |
I was just looking at this as a possible solution to #856 as well. |
I confirmed that pulumi/pulumi#7226 solves this in general, so we won't need an annotation specific to Kubernetes. Here's an example: import * as k8s from "@pulumi/kubernetes";
const appLabels = { app: "nginx" };
const deployment = new k8s.apps.v1.Deployment("nginx", {
spec: {
selector: { matchLabels: appLabels },
replicas: 1,
template: {
metadata: { labels: appLabels },
spec: {
containers: [{ name: "nginx", image: "nginx:1.14"}],
},
},
}
}, {replaceOnChanges: [".spec.replicas"]}); Changing the replicas to 3 shows the following preview: Here's the preview without (This is using |
Just an additional note that you can also do |
Problem description
Some of the resources we use are immutable (in my case, in a weird way).
For example, whenever I try to update my Prometheus resource, I get this :
Reproducing the issue
Create any Prometheus resource, deploy it, change, the image tag try to re-deploy it.
Suggestions for a fix
I've seen that you've created some annotations,
pulumi.com/skipAwait
orpulumi.com/timeoutSeconds
to modify the way things are deployed.It would be nice to add another annotation to force resource replacement.
Because you can't possibly add exceptions for any CRD resource.
Ref: #525
Thanks!
The text was updated successfully, but these errors were encountered: