Skip to content

Commit

Permalink
DOM-37779: Add tag to connect asg to ebs zones (#99)
Browse files Browse the repository at this point in the history
* Add tag to connect asg to ebs zones
  • Loading branch information
Secretions authored May 19, 2022
1 parent b288ec7 commit a141b84
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cdk/domino_cdk/provisioners/eks/eks_nodegroup.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,10 @@ def provision_managed_nodegroup(
instance_types=[ec2.InstanceType(it) for it in ng.instance_types],
launch_template_spec=lts,
labels=ng.labels,
tags=ng.tags,
tags={
**ng.tags,
"k8s.io/cluster-autoscaler/node-template/label/topology.ebs.csi.aws.com/zone": az,
},
node_role=self.ng_role,
)

Expand Down Expand Up @@ -156,6 +159,7 @@ def provision_unmanaged_nodegroup(
**{
f"k8s.io/cluster-autoscaler/{self.cluster.cluster_name}": "owned",
"k8s.io/cluster-autoscaler/enabled": "true",
"k8s.io/cluster-autoscaler/node-template/label/topology.ebs.csi.aws.com/zone": az,
"eks:cluster-name": self.cluster.cluster_name,
"Name": indexed_name,
},
Expand Down

0 comments on commit a141b84

Please sign in to comment.