glamorous-printer-66548
11/06/2018, 6:01 AMcreamy-potato-29402
11/06/2018, 6:02 AMglamorous-printer-66548
11/06/2018, 6:03 AMcreamy-potato-29402
11/06/2018, 6:03 AMglamorous-printer-66548
11/06/2018, 6:04 AMcreamy-potato-29402
11/06/2018, 6:05 AMConfigMap
might get replaced, but that would trigger a rollout, not a replacement of the Deployment
glamorous-printer-66548
11/06/2018, 6:09 AMcreamy-potato-29402
11/06/2018, 6:10 AMConfigMap
is triggering the Deployment
to be replaced?glamorous-printer-66548
11/06/2018, 6:10 AMcreamy-potato-29402
11/06/2018, 6:16 AMConfigMap
replaced, and then the Deployment
is updated..spec.selector
?glamorous-printer-66548
11/06/2018, 6:24 AMimport * as k8s from '@pulumi/kubernetes';
const someDataConfigMap = new k8s.core.v1.ConfigMap('some-config', {
metadata: {
name: 'some-config'
},
data: {
// WHENEVER the value of foo is changed (i.e. change it to `bar2`) pulumi will first delete the deployment and then recreate it
foo: 'bar1'
}
});
const APP_NAME = 'foo';
const labels = {
app: APP_NAME
};
const deployment = new k8s.apps.v1.Deployment(APP_NAME, {
metadata: {
name: APP_NAME
},
spec: {
selector: {
matchLabels: labels
},
template: {
metadata: {
labels
},
spec: {
containers: [
{
name: 'main',
image: 'nginx'
// command: 'f'
}
],
volumes: [
{
name: 'some-data',
configMap: {
name: someDataConfigMap.metadata.apply(metadata => metadata.name)
}
}
]
}
}
}
});
{
"name": "repro-pulumi-bugs",
"devDependencies": {
"@types/node": "latest"
},
"dependencies": {
"@pulumi/kubernetes": "0.17.4",
"@pulumi/pulumi": "latest"
}
}
creamy-potato-29402
11/06/2018, 6:29 AMglamorous-printer-66548
11/06/2018, 6:31 AMcreamy-potato-29402
11/06/2018, 6:42 AMDeployment
unless you change .spec.selector
, so this is is absolutely a bug and we will fix it ASAPglamorous-printer-66548
11/06/2018, 6:46 AMcreamy-potato-29402
11/06/2018, 7:34 AMConfigMap
.glamorous-printer-66548
11/07/2018, 1:32 AMcreamy-potato-29402
11/07/2018, 7:31 PMmicroscopic-florist-22719
creamy-potato-29402
11/07/2018, 7:36 PM