Skip to content

Commit 2ceff77

Browse files
authored
Merge pull request #38 from dataiku/chore/dss13-sc-207469-gke-release-plugin
Sanitize taints (for macros)
2 parents c90f101 + 92bd509 commit 2ceff77

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

python-lib/dku_google/clusters.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,9 @@ def with_nodepool_labels(self, nodepool_labels=[]):
122122

123123
def with_nodepool_taints(self, nodepool_taints=[]):
124124
if nodepool_taints:
125-
logging.info("Adding taints {} to node pool {}".format(nodepool_taints, self.name))
126-
self.nodepool_taints.extend(nodepool_taints)
125+
nodepool_taints_sanitized = [{ "key": taint["key"], "value": taint.get("value", ""), "effect": taint["effect"] } for taint in nodepool_taints]
126+
logging.info("Adding taints {} to node pool {}".format(nodepool_taints_sanitized, self.name))
127+
self.nodepool_taints.extend(nodepool_taints_sanitized)
127128
return self
128129

129130
def with_nodepool_gcp_labels(self, nodepool_gcp_labels={}, cluster_formatted_labels={}):

0 commit comments

Comments
 (0)