From 8ffd609d39fed55eb911ff65b8d5cc60d02c7d55 Mon Sep 17 00:00:00 2001 From: Bryant Biggs Date: Fri, 10 Jan 2025 05:17:36 -0600 Subject: [PATCH] Remove EFA installation scripts; EFA is installed by default on EKS AL2 GPU, EKS Al2023 NVIDIA, and EKS AL2023 Neuron AMIs (#8113) * fix: Remove EFA installation scripts; EFA is installed by default on EKS accelerated AMIs * chore: Update EFA device plugin instances and container image to match `eks-charts` * chore: Clean up dangling reference * fix: Update test for EFA AL2 user data * docs: Update remaining references --- pkg/addons/assets/efa-device-plugin.yaml | 256 +++++++++++++----- pkg/nodebootstrap/README.md | 5 +- pkg/nodebootstrap/al2.go | 4 - pkg/nodebootstrap/al2023.go | 6 - pkg/nodebootstrap/al2023_test.go | 29 +- pkg/nodebootstrap/al2_test.go | 2 +- pkg/nodebootstrap/assets/assets.go | 20 -- pkg/nodebootstrap/assets/scripts/efa.al2.sh | 13 - .../assets/scripts/efa.al2023.sh | 13 - .../scripts/efa.managed.al2023.boothook | 10 - .../assets/scripts/efa.managed.boothook | 10 - pkg/nodebootstrap/managed_al2.go | 5 - pkg/nodebootstrap/managed_al2_test.go | 63 ----- 13 files changed, 192 insertions(+), 244 deletions(-) delete mode 100644 pkg/nodebootstrap/assets/scripts/efa.al2.sh delete mode 100644 pkg/nodebootstrap/assets/scripts/efa.al2023.sh delete mode 100644 pkg/nodebootstrap/assets/scripts/efa.managed.al2023.boothook delete mode 100644 pkg/nodebootstrap/assets/scripts/efa.managed.boothook diff --git a/pkg/addons/assets/efa-device-plugin.yaml b/pkg/addons/assets/efa-device-plugin.yaml index 7227d5ff62..3d2342b8cd 100644 --- a/pkg/addons/assets/efa-device-plugin.yaml +++ b/pkg/addons/assets/efa-device-plugin.yaml @@ -40,135 +40,255 @@ spec: - key: "node.kubernetes.io/instance-type" operator: In values: - - c5n.18xlarge - - c5n.9xlarge - - c5n.metal - - c6a.32xlarge - - c6a.48xlarge - - c6a.metal - - c6gn.16xlarge - - c6i.32xlarge - - c6i.metal - - c6id.32xlarge - - c6id.metal - - dl1.24xlarge - - g4dn.12xlarge - - g4dn.8xlarge - - g4dn.metal - - g5.48xlarge - - g6.8xlarge - - g6.12xlarge - - g6.16xlarge - - g6.24xlarge - - g6.48xlarge - - hpc6a.48xlarge - - hpc7g.16xlarge - - hpc7g.8xlarge - - hpc7g.4xlarge - - i3en.12xlarge - - i3en.24xlarge - - i3en.metal - - i4i.32xlarge - - i4i.metal - - im4gn.16xlarge - - inf1.24xlarge - m5dn.24xlarge - m5dn.metal - m5n.24xlarge - m5n.metal - m5zn.12xlarge - m5zn.metal - - m6a.32xlarge - m6a.48xlarge - m6a.metal - m6i.32xlarge - m6i.metal - m6id.32xlarge - m6id.metal - - p3dn.24xlarge - - p4d.24xlarge - - p4de.24xlarge + - m6idn.32xlarge + - m6idn.metal + - m6in.32xlarge + - m6in.metal + - m7a.48xlarge + - m7a.metal-48xl + - m7g.16xlarge + - m7g.metal + - m7gd.16xlarge + - m7i.48xlarge + - m7i.metal-48xl + - c5n.9xlarge + - c5n.18xlarge + - c5n.metal + - c6a.48xlarge + - c6a.metal + - c6gn.16xlarge + - c6i.32xlarge + - c6i.metal + - c6id.32xlarge + - c6id.metal + - c6in.32xlarge + - c6in.metal + - c7a.48xlarge + - c7a.metal-48xl + - c7g.16xlarge + - c7g.metal + - c7gd.16xlarge + - c7gn.16xlarge + - c7i.48xlarge + - c7i.metal-48xl - r5dn.24xlarge - r5dn.metal - r5n.24xlarge - r5n.metal + - r6a.48xlarge + - r6a.metal - r6i.32xlarge - r6i.metal - - vt1.24xlarge + - r6idn.32xlarge + - r6idn.metal + - r6in.32xlarge + - r6in.metal + - r6id.32xlarge + - r6id.metal + - r7a.48xlarge + - r7a.metal-48xl + - r7g.16xlarge + - r7g.metal + - r7gd.16xlarge + - r7i.48xlarge + - r7i.metal-48xl + - r7iz.32xlarge + - r7iz.metal-32xl - x2idn.32xlarge - x2idn.metal - x2iedn.32xlarge - x2iedn.metal - x2iezn.12xlarge - x2iezn.metal - - matchExpressions: - - key: "node.kubernetes.io/instance-type" - operator: In - values: - - c5n.18xlarge - - c5n.9xlarge - - c5n.metal - - c6a.32xlarge - - c6a.48xlarge - - c6a.metal - - c6gn.16xlarge - - c6i.32xlarge - - c6i.metal - - c6id.32xlarge - - c6id.metal + - i3en.12xlarge + - i3en.24xlarge + - i3en.metal + - i4g.16xlarge + - i4i.32xlarge + - i4i.metal + - im4gn.16xlarge - dl1.24xlarge - - g4dn.12xlarge + - dl2q.24xlarge - g4dn.8xlarge + - g4dn.12xlarge + - g4dn.16xlarge - g4dn.metal + - g5.8xlarge + - g5.12xlarge + - g5.16xlarge + - g5.24xlarge - g5.48xlarge - g6.8xlarge - g6.12xlarge - g6.16xlarge - g6.24xlarge - g6.48xlarge + - g6e.8xlarge + - g6e.12xlarge + - g6e.16xlarge + - g6e.24xlarge + - g6e.48xlarge + - gr6.8xlarge + - inf1.24xlarge + - p3dn.24xlarge + - p4d.24xlarge + - p4de.24xlarge + - p5.48xlarge + - p5e.48xlarge + - p5en.48xlarge + - trn1.32xlarge + - trn1n.32xlarge + - trn2.48xlarge + - vt1.24xlarge - hpc6a.48xlarge - - hpc7g.16xlarge - - hpc7g.8xlarge + - hpc6id.32xlarge + - hpc7a.12xlarge + - hpc7a.24xlarge + - hpc7a.48xlarge + - hpc7a.96xlarge - hpc7g.4xlarge - - i3en.12xlarge - - i3en.24xlarge - - i3en.metal - - i4i.32xlarge - - i4i.metal - - im4gn.16xlarge - - inf1.24xlarge + - hpc7g.8xlarge + - hpc7g.16xlarge + - matchExpressions: + - key: "node.kubernetes.io/instance-type" + operator: In + values: - m5dn.24xlarge - m5dn.metal - m5n.24xlarge - m5n.metal - m5zn.12xlarge - m5zn.metal - - m6a.32xlarge - m6a.48xlarge - m6a.metal - m6i.32xlarge - m6i.metal - m6id.32xlarge - m6id.metal - - p3dn.24xlarge - - p4d.24xlarge - - p4de.24xlarge + - m6idn.32xlarge + - m6idn.metal + - m6in.32xlarge + - m6in.metal + - m7a.48xlarge + - m7a.metal-48xl + - m7g.16xlarge + - m7g.metal + - m7gd.16xlarge + - m7i.48xlarge + - m7i.metal-48xl + - c5n.9xlarge + - c5n.18xlarge + - c5n.metal + - c6a.48xlarge + - c6a.metal + - c6gn.16xlarge + - c6i.32xlarge + - c6i.metal + - c6id.32xlarge + - c6id.metal + - c6in.32xlarge + - c6in.metal + - c7a.48xlarge + - c7a.metal-48xl + - c7g.16xlarge + - c7g.metal + - c7gd.16xlarge + - c7gn.16xlarge + - c7i.48xlarge + - c7i.metal-48xl - r5dn.24xlarge - r5dn.metal - r5n.24xlarge - r5n.metal + - r6a.48xlarge + - r6a.metal - r6i.32xlarge - r6i.metal - - vt1.24xlarge + - r6idn.32xlarge + - r6idn.metal + - r6in.32xlarge + - r6in.metal + - r6id.32xlarge + - r6id.metal + - r7a.48xlarge + - r7a.metal-48xl + - r7g.16xlarge + - r7g.metal + - r7gd.16xlarge + - r7i.48xlarge + - r7i.metal-48xl + - r7iz.32xlarge + - r7iz.metal-32xl - x2idn.32xlarge - x2idn.metal - x2iedn.32xlarge - x2iedn.metal - x2iezn.12xlarge - x2iezn.metal + - i3en.12xlarge + - i3en.24xlarge + - i3en.metal + - i4g.16xlarge + - i4i.32xlarge + - i4i.metal + - im4gn.16xlarge + - dl1.24xlarge + - dl2q.24xlarge + - g4dn.8xlarge + - g4dn.12xlarge + - g4dn.16xlarge + - g4dn.metal + - g5.8xlarge + - g5.12xlarge + - g5.16xlarge + - g5.24xlarge + - g5.48xlarge + - g6.8xlarge + - g6.12xlarge + - g6.16xlarge + - g6.24xlarge + - g6.48xlarge + - g6e.8xlarge + - g6e.12xlarge + - g6e.16xlarge + - g6e.24xlarge + - g6e.48xlarge + - gr6.8xlarge + - inf1.24xlarge + - p3dn.24xlarge + - p4d.24xlarge + - p4de.24xlarge + - p5.48xlarge + - p5e.48xlarge + - p5en.48xlarge + - trn1.32xlarge + - trn1n.32xlarge + - trn2.48xlarge + - vt1.24xlarge + - hpc6a.48xlarge + - hpc6id.32xlarge + - hpc7a.12xlarge + - hpc7a.24xlarge + - hpc7a.48xlarge + - hpc7a.96xlarge + - hpc7g.4xlarge + - hpc7g.8xlarge + - hpc7g.16xlarge hostNetwork: true containers: - - image: "%s.dkr.ecr.%s.%s/eks/aws-efa-k8s-device-plugin:v0.3.3" + - image: "%s.dkr.ecr.%s.%s/eks/aws-efa-k8s-device-plugin:v0.5.4" name: aws-efa-k8s-device-plugin securityContext: allowPrivilegeEscalation: false diff --git a/pkg/nodebootstrap/README.md b/pkg/nodebootstrap/README.md index 37eef5f547..ca96673fdc 100644 --- a/pkg/nodebootstrap/README.md +++ b/pkg/nodebootstrap/README.md @@ -40,7 +40,7 @@ The call to `UserData` will also dynamically add the following: The bootstrap wrapper scripts will use `jq` and `sed` to get user and our config into various files, and then call `/etc/eks/bootstrap.sh`. -For AL2, enabling either SSM or EFA will add `assets/install-ssm.al2.sh` or `assets/efa.al2.sh`. +For AL2, enabling SSM will add `assets/install-ssm.al2.sh`. ### AmazonLinux2023 @@ -73,7 +73,7 @@ spec: ``` -For EKS-managed nodes based on native AMIs, the userdata above is fulfilled automatically by the AWS SSM agent. +For EKS-managed nodes based on native AMIs, the userdata above is fulfilled automatically by the AWS SSM agent. ## Troubleshooting @@ -111,6 +111,5 @@ Files: /var/lib/cloud/scripts/eksctl/bootstrap.al2.sh /etc/kubernetes/kubelet/kubelet-config.json /etc/docker/daemon.json -/var/lib/cloud/scripts/eksctl/efa.al2.sh /var/lib/cloud/scripts/eksctl/install-ssm.sh ``` diff --git a/pkg/nodebootstrap/al2.go b/pkg/nodebootstrap/al2.go index 32bc532c63..c5f797e8fd 100644 --- a/pkg/nodebootstrap/al2.go +++ b/pkg/nodebootstrap/al2.go @@ -29,10 +29,6 @@ func NewAL2Bootstrapper(clusterConfig *api.ClusterConfig, ng *api.NodeGroup, clu func (b *AmazonLinux2) UserData() (string, error) { var scripts []script - if api.IsEnabled(b.ng.EFAEnabled) { - scripts = append(scripts, script{name: "efa.al2.sh", contents: assets.EfaAl2Sh}) - } - body, err := linuxConfig(b.clusterConfig, al2BootScript, assets.BootstrapAl2Sh, b.clusterDNS, b.ng, scripts...) if err != nil { return "", errors.Wrap(err, "encoding user data") diff --git a/pkg/nodebootstrap/al2023.go b/pkg/nodebootstrap/al2023.go index bb4bf8f8f7..d83f00bc0d 100644 --- a/pkg/nodebootstrap/al2023.go +++ b/pkg/nodebootstrap/al2023.go @@ -32,17 +32,11 @@ type AL2023 struct { func NewManagedAL2023Bootstrapper(cfg *api.ClusterConfig, mng *api.ManagedNodeGroup, clusterDNS string) *AL2023 { al2023 := newAL2023Bootstrapper(cfg, mng, clusterDNS) - if api.IsEnabled(mng.EFAEnabled) { - al2023.cloudboot = append(al2023.cloudboot, assets.EfaManagedAL2023Boothook) - } return al2023 } func NewAL2023Bootstrapper(cfg *api.ClusterConfig, ng *api.NodeGroup, clusterDNS string) *AL2023 { al2023 := newAL2023Bootstrapper(cfg, ng, clusterDNS) - if api.IsEnabled(ng.EFAEnabled) { - al2023.scripts = append(al2023.scripts, assets.EfaAl2023Sh) - } return al2023 } diff --git a/pkg/nodebootstrap/al2023_test.go b/pkg/nodebootstrap/al2023_test.go index 7a81c30707..f37b37b972 100644 --- a/pkg/nodebootstrap/al2023_test.go +++ b/pkg/nodebootstrap/al2023_test.go @@ -68,7 +68,7 @@ var _ = DescribeTable("Unmanaged AL2023", func(e al2023Entry) { overrideNodegroupSettings: func(np api.NodePool) { np.BaseNodeGroup().EFAEnabled = aws.Bool(true) }, - expectedUserData: wrapMIMEParts(xTablesLock + efaScript + nodeConfig), + expectedUserData: wrapMIMEParts(xTablesLock + nodeConfig), }), ) @@ -99,25 +99,12 @@ var _ = DescribeTable("Managed AL2023", func(e al2023Entry) { Entry("native AMI", al2023Entry{ expectedUserData: wrapMIMEParts(xTablesLock), }), - Entry("native AMI && EFA enabled", al2023Entry{ - overrideNodegroupSettings: func(np api.NodePool) { - np.BaseNodeGroup().EFAEnabled = aws.Bool(true) - }, - expectedUserData: wrapMIMEParts(xTablesLock + efaCloudhook), - }), Entry("custom AMI", al2023Entry{ overrideNodegroupSettings: func(np api.NodePool) { np.BaseNodeGroup().AMI = "ami-xxxx" }, expectedUserData: wrapMIMEParts(xTablesLock + managedNodeConfig), }), - Entry("custom AMI && EFA enabled", al2023Entry{ - overrideNodegroupSettings: func(np api.NodePool) { - np.BaseNodeGroup().AMI = "ami-xxxx" - np.BaseNodeGroup().EFAEnabled = aws.Bool(true) - }, - expectedUserData: wrapMIMEParts(xTablesLock + efaCloudhook + managedNodeConfig), - }), ) type al2023OverrideNodeConfigEntry struct { @@ -400,20 +387,6 @@ Content-Type: charset="us-ascii" %s `, assets.AL2023XTablesLock) - efaCloudhook = fmt.Sprintf(`--// -Content-Type: text/cloud-boothook -Content-Type: charset="us-ascii" - -%s -`, assets.EfaManagedAL2023Boothook) - - efaScript = fmt.Sprintf(`--// -Content-Type: text/x-shellscript -Content-Type: charset="us-ascii" - -%s -`, assets.EfaAl2023Sh) - nodeConfig = `--// Content-Type: application/node.eks.aws diff --git a/pkg/nodebootstrap/al2_test.go b/pkg/nodebootstrap/al2_test.go index 096d0c678d..191075437c 100644 --- a/pkg/nodebootstrap/al2_test.go +++ b/pkg/nodebootstrap/al2_test.go @@ -63,7 +63,7 @@ var _ = Describe("AmazonLinux2 User Data", func() { Expect(err).NotTo(HaveOccurred()) cloudCfg := decode(userData) - Expect(cloudCfg.WriteFiles[2].Path).To(Equal("/var/lib/cloud/scripts/eksctl/efa.al2.sh")) + Expect(cloudCfg.WriteFiles[2].Path).To(Equal("/var/lib/cloud/scripts/eksctl/bootstrap.al2.sh")) Expect(cloudCfg.WriteFiles[2].Permissions).To(Equal("0755")) }) }) diff --git a/pkg/nodebootstrap/assets/assets.go b/pkg/nodebootstrap/assets/assets.go index 94fdc480b2..16175ba381 100644 --- a/pkg/nodebootstrap/assets/assets.go +++ b/pkg/nodebootstrap/assets/assets.go @@ -25,26 +25,6 @@ var BootstrapUbuntuSh string //go:embed scripts/al2023-xtables.lock.sh var AL2023XTablesLock string -// EfaAl2Sh holds the efa.al2.sh contents -// -//go:embed scripts/efa.al2.sh -var EfaAl2Sh string - -// EfaAl2023Sh holds the efa.al2023.sh contents -// -//go:embed scripts/efa.al2023.sh -var EfaAl2023Sh string - -// EfaManagedBoothook holds the efa.managed.boothook contents -// -//go:embed scripts/efa.managed.boothook -var EfaManagedBoothook string - -// EfaManagedAL2023Boothook holds the efa.managed.al2023.boothook contents -// -//go:embed scripts/efa.managed.al2023.boothook -var EfaManagedAL2023Boothook string - // InstallSsmAl2Sh holds the install-ssm.al2.sh contents // //go:embed scripts/install-ssm.al2.sh diff --git a/pkg/nodebootstrap/assets/scripts/efa.al2.sh b/pkg/nodebootstrap/assets/scripts/efa.al2.sh deleted file mode 100644 index f99ae6b962..0000000000 --- a/pkg/nodebootstrap/assets/scripts/efa.al2.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash - -set -o errexit -set -o pipefail -set -o nounset - -yum install -y wget -wget -q --timeout=20 https://s3-us-west-2.amazonaws.com/aws-efa-installer/aws-efa-installer-latest.tar.gz -O /tmp/aws-efa-installer.tar.gz -tar -xf /tmp/aws-efa-installer.tar.gz -C /tmp -rm -rf /tmp/aws-efa-installer.tar.gz -cd /tmp/aws-efa-installer -./efa_installer.sh -y -g -/opt/amazon/efa/bin/fi_info -p efa diff --git a/pkg/nodebootstrap/assets/scripts/efa.al2023.sh b/pkg/nodebootstrap/assets/scripts/efa.al2023.sh deleted file mode 100644 index b73f630813..0000000000 --- a/pkg/nodebootstrap/assets/scripts/efa.al2023.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash - -set -o errexit -set -o pipefail -set -o nounset - -dnf install -y wget -wget -q --timeout=20 https://s3-us-west-2.amazonaws.com/aws-efa-installer/aws-efa-installer-latest.tar.gz -O /tmp/aws-efa-installer.tar.gz -tar -xf /tmp/aws-efa-installer.tar.gz -C /tmp -rm -rf /tmp/aws-efa-installer.tar.gz -cd /tmp/aws-efa-installer -./efa_installer.sh -y -g -/opt/amazon/efa/bin/fi_info -p efa diff --git a/pkg/nodebootstrap/assets/scripts/efa.managed.al2023.boothook b/pkg/nodebootstrap/assets/scripts/efa.managed.al2023.boothook deleted file mode 100644 index d8440a4520..0000000000 --- a/pkg/nodebootstrap/assets/scripts/efa.managed.al2023.boothook +++ /dev/null @@ -1,10 +0,0 @@ -cloud-init-per once dnf_wget dnf install -y wget -cloud-init-per once wget_efa wget -q --timeout=20 https://s3-us-west-2.amazonaws.com/aws-efa-installer/aws-efa-installer-latest.tar.gz -O /tmp/aws-efa-installer-latest.tar.gz - -cloud-init-per once tar_efa tar -xf /tmp/aws-efa-installer-latest.tar.gz -C /tmp -cloud-init-per once rm_efa_gz rm -rf /tmp/aws-efa-installer-latest.tar.gz -pushd /tmp/aws-efa-installer -cloud-init-per once install_efa ./efa_installer.sh -y -g -pop /tmp/aws-efa-installer - -cloud-init-per once efa_info /opt/amazon/efa/bin/fi_info -p efa diff --git a/pkg/nodebootstrap/assets/scripts/efa.managed.boothook b/pkg/nodebootstrap/assets/scripts/efa.managed.boothook deleted file mode 100644 index d2863d42c6..0000000000 --- a/pkg/nodebootstrap/assets/scripts/efa.managed.boothook +++ /dev/null @@ -1,10 +0,0 @@ -cloud-init-per once yum_wget yum install -y wget -cloud-init-per once wget_efa wget -q --timeout=20 https://s3-us-west-2.amazonaws.com/aws-efa-installer/aws-efa-installer-latest.tar.gz -O /tmp/aws-efa-installer-latest.tar.gz - -cloud-init-per once tar_efa tar -xf /tmp/aws-efa-installer-latest.tar.gz -C /tmp -cloud-init-per once rm_efa_gz rm -rf /tmp/aws-efa-installer-latest.tar.gz -pushd /tmp/aws-efa-installer -cloud-init-per once install_efa ./efa_installer.sh -y -g -pop /tmp/aws-efa-installer - -cloud-init-per once efa_info /opt/amazon/efa/bin/fi_info -p efa diff --git a/pkg/nodebootstrap/managed_al2.go b/pkg/nodebootstrap/managed_al2.go index f868116377..fa734f8a72 100644 --- a/pkg/nodebootstrap/managed_al2.go +++ b/pkg/nodebootstrap/managed_al2.go @@ -13,7 +13,6 @@ import ( "sigs.k8s.io/yaml" api "github.com/weaveworks/eksctl/pkg/apis/eksctl.io/v1alpha5" - "github.com/weaveworks/eksctl/pkg/nodebootstrap/assets" ) // ManagedAL2 is a bootstrapper for managed Amazon Linux 2 nodegroups @@ -54,10 +53,6 @@ func (m *ManagedAL2) UserData() (string, error) { scripts = append(scripts, makeMaxPodsScript(ng.MaxPodsPerNode)) } - if api.IsEnabled(ng.EFAEnabled) { - cloudboot = append(cloudboot, assets.EfaManagedBoothook) - } - if len(scripts) == 0 && len(cloudboot) == 0 { return "", nil } diff --git a/pkg/nodebootstrap/managed_al2_test.go b/pkg/nodebootstrap/managed_al2_test.go index 6b9c08dcd4..b373769ebd 100644 --- a/pkg/nodebootstrap/managed_al2_test.go +++ b/pkg/nodebootstrap/managed_al2_test.go @@ -88,69 +88,6 @@ B64_CLUSTER_CA=dGVzdAo= API_SERVER_URL=https://test.com /etc/eks/bootstrap.sh launch-template --b64-cluster-ca $B64_CLUSTER_CA --apiserver-endpoint $API_SERVER_URL ---//-- -`, - }), - - Entry("EFA enabled", managedEntry{ - ng: &api.ManagedNodeGroup{ - NodeGroupBase: &api.NodeGroupBase{ - Name: "ng", - EFAEnabled: api.Enabled(), - }, - }, - - expectedUserData: `MIME-Version: 1.0 -Content-Type: multipart/mixed; boundary=// - ---// -Content-Type: text/cloud-boothook -Content-Type: charset="us-ascii" - -cloud-init-per once yum_wget yum install -y wget -cloud-init-per once wget_efa wget -q --timeout=20 https://s3-us-west-2.amazonaws.com/aws-efa-installer/aws-efa-installer-latest.tar.gz -O /tmp/aws-efa-installer-latest.tar.gz - -cloud-init-per once tar_efa tar -xf /tmp/aws-efa-installer-latest.tar.gz -C /tmp -cloud-init-per once rm_efa_gz rm -rf /tmp/aws-efa-installer-latest.tar.gz -pushd /tmp/aws-efa-installer -cloud-init-per once install_efa ./efa_installer.sh -y -g -pop /tmp/aws-efa-installer - -cloud-init-per once efa_info /opt/amazon/efa/bin/fi_info -p efa - ---//-- -`, - }), - - Entry("EFA and SSM enabled", managedEntry{ - ng: &api.ManagedNodeGroup{ - NodeGroupBase: &api.NodeGroupBase{ - Name: "ng", - EFAEnabled: api.Enabled(), - SSH: &api.NodeGroupSSH{ - Allow: api.Enabled(), - EnableSSM: api.Enabled(), - }, - }, - }, - expectedUserData: `MIME-Version: 1.0 -Content-Type: multipart/mixed; boundary=// - ---// -Content-Type: text/cloud-boothook -Content-Type: charset="us-ascii" - -cloud-init-per once yum_wget yum install -y wget -cloud-init-per once wget_efa wget -q --timeout=20 https://s3-us-west-2.amazonaws.com/aws-efa-installer/aws-efa-installer-latest.tar.gz -O /tmp/aws-efa-installer-latest.tar.gz - -cloud-init-per once tar_efa tar -xf /tmp/aws-efa-installer-latest.tar.gz -C /tmp -cloud-init-per once rm_efa_gz rm -rf /tmp/aws-efa-installer-latest.tar.gz -pushd /tmp/aws-efa-installer -cloud-init-per once install_efa ./efa_installer.sh -y -g -pop /tmp/aws-efa-installer - -cloud-init-per once efa_info /opt/amazon/efa/bin/fi_info -p efa - --//-- `, }),