You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Important: update status BEFORE deleting, otherwise we will start reconciling this instance, before it's completely deleted
323
323
updateStatus(shinyProxy) {
324
324
it.status.instances.remove(shinyProxyInstance)
325
325
}
326
-
for (service in resourceRetriever.getServiceByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
327
-
kubernetesClient.resource(service).delete()
328
-
}
329
-
for (replicaSet in resourceRetriever.getReplicaSetByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
330
-
kubernetesClient.resource(replicaSet).delete()
331
-
}
332
-
for (configMap in resourceRetriever.getConfigMapByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
333
-
kubernetesClient.resource(configMap).delete()
326
+
327
+
// Important: remove ingress before removing the ReplicaSet. This ensures that the rotues are correclty updated in the Ingress
for (service in resourceRetriever.getServiceByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
338
+
kubernetesClient.resource(service).delete()
339
+
}
340
+
for (replicaSet in resourceRetriever.getReplicaSetByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
341
+
kubernetesClient.resource(replicaSet).delete()
342
+
}
343
+
for (configMap in resourceRetriever.getConfigMapByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
for (ingress in resourceRetriever.getIngressByLabels(LabelFactory.labelsForShinyProxyInstance(shinyProxy, shinyProxyInstance), shinyProxy.metadata.namespace)) {
0 commit comments