Skip to content

Commit 919740b

Browse files
authored
Merge pull request #402 from dims/move-from-ubuntu-22.04-to-24.04
Switch Ubuntu from 22.04 to 24.04
2 parents 00afb06 + ab5184d commit 919740b

File tree

6 files changed

+17
-17
lines changed

6 files changed

+17
-17
lines changed

.github/workflows/update-deps.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ permissions:
1515
jobs:
1616
update-deps:
1717
if: ${{ github.repository == 'kubernetes-sigs/provider-aws-test-infra' }}
18-
runs-on: ubuntu-22.04
18+
runs-on: ubuntu-24.04
1919
steps:
2020
- name: Checkout provider-aws-test-infra
2121
uses: actions/checkout@v4
@@ -51,4 +51,4 @@ jobs:
5151
labels: ok-to-test
5252
body: |
5353
Updating go.mod with latest kubernetes related dependencies...
54-
path: src/sigs.k8s.io/provider-aws-test-infra
54+
path: src/sigs.k8s.io/provider-aws-test-infra

config/aws-instance-arm64.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ images:
33
ssm_path: /aws/service/ami-amazon-linux-latest/al2023-ami-kernel-6.1-arm64
44
instance_type: m6g.large
55
user_data_file: al2023-6.1.yaml
6-
ubuntu-2204:
7-
ssm_path: /aws/service/canonical/ubuntu/server/jammy/stable/current/arm64/hvm/ebs-gp2/ami-id
6+
ubuntu-2404:
7+
ssm_path: /aws/service/canonical/ubuntu/server/noble/stable/current/arm64/hvm/ebs-gp3/ami-id
88
instance_type: m6g.large
9-
user_data_file: ubuntu2204.yaml
9+
user_data_file: ubuntu2404.yaml

config/aws-instance.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ images:
33
ssm_path: /aws/service/ami-amazon-linux-latest/al2023-ami-kernel-6.1-x86_64
44
instance_type: m6a.large
55
user_data_file: al2023-6.1.yaml
6-
ubuntu-2204:
7-
ssm_path: /aws/service/canonical/ubuntu/server/jammy/stable/current/amd64/hvm/ebs-gp2/ami-id
6+
ubuntu-2404:
7+
ssm_path: /aws/service/canonical/ubuntu/server/noble/stable/current/amd64/hvm/ebs-gp3/ami-id
88
instance_type: m6a.large
9-
user_data_file: ubuntu2204.yaml
9+
user_data_file: ubuntu2404.yaml

config/ubuntu2204.yaml config/ubuntu2404.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#cloud-config
2-
# This bootstraps a public ubuntu 2204 image from scratch.
2+
# This bootstraps a public ubuntu 24.04 image from scratch.
33
system_info:
44
default_user:
55
name: ec2-user

kubetest2-ec2/config/ubuntu2204.yaml kubetest2-ec2/config/ubuntu2404.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ packages:
99
- nfs-common
1010
- socat
1111
- conntrack
12-
- awscli
1312
- net-tools
1413
- jq
1514
- python3
@@ -86,6 +85,7 @@ write_files:
8685
owner: root
8786
permissions: '0544'
8887
runcmd:
88+
- snap install aws-cli --classic
8989
- ufw disable || echo "ufw not installed"
9090
- systemctl stop apparmor
9191
- systemctl disable apparmor

kubetest2-ec2/pkg/deployer/runner.go

+7-7
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,9 @@ func (a *AWSRunner) Validate() error {
120120
a.deployer.UserDataFile = "al2023.sh"
121121
}
122122
case "ubuntu", "":
123-
path = "/aws/service/canonical/ubuntu/server/jammy/stable/current/" + arch + "/hvm/ebs-gp2/ami-id"
123+
path = "/aws/service/canonical/ubuntu/server/noble/stable/current/" + arch + "/hvm/ebs-gp3/ami-id"
124124
if a.deployer.UserDataFile == "" {
125-
a.deployer.UserDataFile = "ubuntu2204.yaml"
125+
a.deployer.UserDataFile = "ubuntu2404.yaml"
126126
}
127127
default:
128128
return fmt.Errorf("unrecognized parameter --image : %s", a.deployer.Image)
@@ -182,9 +182,9 @@ func (a *AWSRunner) Validate() error {
182182
a.deployer.WorkerUserDataFile = "al2023.sh"
183183
}
184184
case "ubuntu", "":
185-
path = "/aws/service/canonical/ubuntu/server/jammy/stable/current/" + arch + "/hvm/ebs-gp2/ami-id"
185+
path = "/aws/service/canonical/ubuntu/server/noble/stable/current/" + arch + "/hvm/ebs-gp3/ami-id"
186186
if a.deployer.WorkerUserDataFile == "" {
187-
a.deployer.WorkerUserDataFile = "ubuntu2204.yaml"
187+
a.deployer.WorkerUserDataFile = "ubuntu2404.yaml"
188188
}
189189
default:
190190
return fmt.Errorf("unrecognized parameter --worker-image : %s", a.deployer.WorkerImage)
@@ -462,11 +462,11 @@ func (a *AWSRunner) getUserData(dataFile string, version string, controlPlane bo
462462
userdata = string(userDataBytes)
463463
}
464464
} else {
465-
userDataBytes, err := config.ConfigFS.ReadFile("ubuntu2204.yaml")
465+
userDataBytes, err := config.ConfigFS.ReadFile("ubuntu2404.yaml")
466466
if err != nil {
467-
return "", fmt.Errorf("error reading embedded ubuntu2204.yaml: %w", err)
467+
return "", fmt.Errorf("error reading embedded ubuntu2404.yaml: %w", err)
468468
}
469-
klog.Infof("loading user data from embedded file: ubuntu2204.yaml")
469+
klog.Infof("loading user data from embedded file: ubuntu2404.yaml")
470470
userdata = string(userDataBytes)
471471
}
472472

0 commit comments

Comments
 (0)