Skip to content

Commit 3214829

Browse files
authored
Merge branch 'main' into fix/msiexec-hang-qn-norestart
2 parents bdf87f8 + e80670d commit 3214829

221 files changed

Lines changed: 21485 additions & 1583 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/build-check.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ jobs:
1818
runs-on: ${{ matrix.os }}
1919
steps:
2020
- name: Install Terraform
21-
uses: hashicorp/setup-terraform@v3
21+
uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd # v3.1.2
2222
- name: Verify Terraform version
2323
run: terraform --version
24-
- uses: actions/checkout@v3
24+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
2525
- name: Setup Go
26-
uses: actions/setup-go@v3
26+
uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # v3.5.0
2727
with:
2828
go-version: ~1.23.0
2929
- name: Lint Terraform

.github/workflows/codeql-analysis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ jobs:
1616
codeql-analyze:
1717
runs-on: ubuntu-latest
1818
steps:
19-
- uses: actions/checkout@v3
19+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
2020

2121
- name: Initialize CodeQL
22-
uses: github/codeql-action/init@v2
22+
uses: github/codeql-action/init@b8d3b6e8af63cde30bdc382c0bc28114f4346c88 # v2.28.1
2323
with:
2424
languages: go
2525

2626
- name: Perform CodeQL Analysis
27-
uses: github/codeql-action/analyze@v2
27+
uses: github/codeql-action/analyze@b8d3b6e8af63cde30bdc382c0bc28114f4346c88 # v2.28.1

environment/computetype/compute_type.go

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,20 @@ const (
1111
EC2 ComputeType = "EC2"
1212
ECS ComputeType = "ECS"
1313
EKS ComputeType = "EKS"
14+
// AzureVM is a non-AWS host authenticating to AWS via the Azure web-identity credential chain.
15+
AzureVM ComputeType = "AZUREVM"
16+
// AKS is an Azure Kubernetes Service cluster authenticating to AWS via the projected
17+
// service-account web-identity credential chain.
18+
AKS ComputeType = "AKS"
1419
)
1520

1621
var (
1722
computeTypes = map[string]ComputeType{
18-
"EC2": EC2,
19-
"ECS": ECS,
20-
"EKS": EKS,
23+
"EC2": EC2,
24+
"ECS": ECS,
25+
"EKS": EKS,
26+
"AZUREVM": AzureVM,
27+
"AKS": AKS,
2128
}
2229
)
2330

environment/metadata.go

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ type MetaData struct {
3939
CwaCommitSha string
4040
CaCertPath string
4141
EKSClusterName string
42+
AKSClusterName string
4243
ProxyUrl string
4344
AssumeRoleArn string
4445
InstanceArn string
@@ -86,6 +87,7 @@ type MetaDataStrings struct {
8687
CwaCommitSha string
8788
CaCertPath string
8889
EKSClusterName string
90+
AKSClusterName string
8991
ProxyUrl string
9092
AssumeRoleArn string
9193
InstanceArn string
@@ -119,7 +121,7 @@ type MetaDataStrings struct {
119121
}
120122

121123
func registerComputeType(dataString *MetaDataStrings) {
122-
flag.StringVar(&(dataString.ComputeType), "computeType", "", "EC2/ECS/EKS")
124+
flag.StringVar(&(dataString.ComputeType), "computeType", "", "EC2/ECS/EKS/AZUREVM/AKS")
123125
}
124126
func registerBucket(dataString *MetaDataStrings) {
125127
flag.StringVar(&(dataString.Bucket), "bucket", "", "s3 bucket ex cloudwatch-agent-integration-bucket")
@@ -142,6 +144,10 @@ func registerECSData(dataString *MetaDataStrings) {
142144
flag.StringVar(&(dataString.EcsServiceName), "cwagentECSServiceName", "", "Used to restart ecs task to apply new agent config")
143145
}
144146

147+
func registerAKSData(d *MetaDataStrings) {
148+
flag.StringVar(&(d.AKSClusterName), "aksClusterName", "", "AKS cluster name")
149+
}
150+
145151
func registerEKSData(d *MetaDataStrings) {
146152
flag.StringVar(&(d.EKSClusterName), "eksClusterName", "", "EKS cluster name")
147153
flag.StringVar(&(d.EksDeploymentStrategy), "eksDeploymentStrategy", "", "Daemon/Replica/Sidecar")
@@ -187,7 +193,7 @@ func registerProxyUrl(dataString *MetaDataStrings) {
187193
func fillComputeType(e *MetaData, data *MetaDataStrings) {
188194
computeType, ok := computetype.FromString(data.ComputeType)
189195
if !ok {
190-
log.Panic("Invalid compute type. Needs to be EC2/ECS/EKS. Compute Type is a required flag. :" + data.ComputeType)
196+
log.Panic("Invalid compute type. Needs to be EC2/ECS/EKS/AZUREVM/AKS. Compute Type is a required flag. :" + data.ComputeType)
191197
}
192198
e.ComputeType = computeType
193199
}
@@ -321,6 +327,7 @@ func RegisterEnvironmentMetaDataFlags() *MetaDataStrings {
321327
registerComputeType(registeredMetaDataStrings)
322328
registerECSData(registeredMetaDataStrings)
323329
registerEKSData(registeredMetaDataStrings)
330+
registerAKSData(registeredMetaDataStrings)
324331
registerEKSE2ETestData(registeredMetaDataStrings)
325332
registerBucket(registeredMetaDataStrings)
326333
registerS3Key(registeredMetaDataStrings)
@@ -359,6 +366,7 @@ func GetEnvironmentMetaData() *MetaData {
359366
metaDataStorage.AssumeRoleArn = registeredMetaDataStrings.AssumeRoleArn
360367
metaDataStorage.InstanceArn = registeredMetaDataStrings.InstanceArn
361368
metaDataStorage.InstanceId = registeredMetaDataStrings.InstanceId
369+
metaDataStorage.AKSClusterName = registeredMetaDataStrings.AKSClusterName
362370
metaDataStorage.InstancePlatform = registeredMetaDataStrings.InstancePlatform
363371
metaDataStorage.AgentStartCommand = registeredMetaDataStrings.AgentStartCommand
364372
metaDataStorage.EksGpuType = registeredMetaDataStrings.EksGpuType
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[
2+
{
3+
"os": "al2023",
4+
"username": "ec2-user",
5+
"instanceType": "c5n.9xlarge",
6+
"installAgentCommand": "go run ./install/install_agent.go rpm",
7+
"ami": "cloudwatch-agent-integration-test-x86-al2023*",
8+
"caCertPath": "/etc/ssl/certs/ca-bundle.crt",
9+
"arc": "amd64",
10+
"binaryName": "amazon-cloudwatch-agent.rpm",
11+
"family": "linux"
12+
}
13+
]

generator/resources/ec2_linux_test_matrix.json

Lines changed: 45 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"username": "ubuntu",
55
"instanceType":"t3a.medium",
66
"installAgentCommand": "go run ./install/install_agent.go deb",
7-
"ami": "cloudwatch-agent-integration-test-ubuntu-LTS-22*",
7+
"ami": "cloudwatch-agent-integration-test-ubuntu-LTS-2220*",
88
"caCertPath": "/etc/ssl/certs/ca-certificates.crt",
99
"arc": "amd64",
1010
"binaryName": "amazon-cloudwatch-agent.deb",
@@ -32,6 +32,17 @@
3232
"binaryName": "amazon-cloudwatch-agent.deb",
3333
"family": "linux"
3434
},
35+
{
36+
"os": "ubuntu-22.04",
37+
"username": "ubuntu",
38+
"instanceType": "m6g.medium",
39+
"installAgentCommand": "go run ./install/install_agent.go deb",
40+
"ami": "cloudwatch-agent-integration-test-ubuntu-LTS-22-arm64 20*",
41+
"caCertPath": "/etc/ssl/certs/ca-certificates.crt",
42+
"arc": "arm64",
43+
"binaryName": "amazon-cloudwatch-agent.deb",
44+
"family": "linux"
45+
},
3546
{
3647
"os": "debian-12",
3748
"username": "admin",
@@ -197,6 +208,17 @@
197208
"binaryName": "amazon-cloudwatch-agent.rpm",
198209
"family": "linux"
199210
},
211+
{
212+
"os": "rhel8",
213+
"username": "ec2-user",
214+
"instanceType": "m6g.medium",
215+
"installAgentCommand": "go run ./install/install_agent.go rpm",
216+
"ami": "cloudwatch-agent-integration-test-rhel8-arm64 20*",
217+
"caCertPath": "/etc/ssl/certs/ca-bundle.crt",
218+
"arc": "arm64",
219+
"binaryName": "amazon-cloudwatch-agent.rpm",
220+
"family": "linux"
221+
},
200222
{
201223
"os": "rhel10",
202224
"username": "ec2-user",
@@ -207,5 +229,27 @@
207229
"arc": "amd64",
208230
"binaryName": "amazon-cloudwatch-agent.rpm",
209231
"family": "linux"
232+
},
233+
{
234+
"os": "sles-15",
235+
"username": "ec2-user",
236+
"instanceType": "t3a.medium",
237+
"installAgentCommand": "go run ./install/install_agent.go rpm",
238+
"ami": "cloudwatch-agent-integration-test-sles-15 20*",
239+
"caCertPath": "/var/lib/ca-certificates/ca-bundle.pem",
240+
"arc": "amd64",
241+
"binaryName": "amazon-cloudwatch-agent.rpm",
242+
"family": "linux"
243+
},
244+
{
245+
"os": "sles-15",
246+
"username": "ec2-user",
247+
"instanceType": "m6g.medium",
248+
"installAgentCommand": "go run ./install/install_agent.go rpm",
249+
"ami": "cloudwatch-agent-integration-test-sles-15-arm64 20*",
250+
"caCertPath": "/var/lib/ca-certificates/ca-bundle.pem",
251+
"arc": "arm64",
252+
"binaryName": "amazon-cloudwatch-agent.rpm",
253+
"family": "linux"
210254
}
211255
]

generator/resources/ec2_windows_test_matrix.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,43 @@
11
[
22
{
33
"os": "win-11",
4-
"instanceType":"t3a.medium",
4+
"instanceType":"t3a.large",
55
"ami": "cloudwatch-agent-integration-test-win-11*",
66
"useSSM": false
77
},
88
{
99
"os": "win-2016",
10-
"instanceType":"t3a.medium",
10+
"instanceType":"t3a.large",
1111
"ami": "cloudwatch-agent-integration-test-win-2016*",
1212
"useSSM": false
1313
},
1414
{
1515
"os": "win-2019",
16-
"instanceType":"t3a.medium",
16+
"instanceType":"t3a.large",
1717
"ami": "cloudwatch-agent-integration-test-win-2019*",
1818
"useSSM": false
1919
},
2020
{
2121
"os": "win-2022",
22-
"instanceType":"t3a.medium",
22+
"instanceType":"t3a.large",
2323
"ami": "cloudwatch-agent-integration-test-win-2022*",
2424
"useSSM": false
2525
},
2626
{
2727
"os": "win-2022",
28-
"instanceType":"t3a.medium",
28+
"instanceType":"t3a.large",
2929
"ami": "cloudwatch-agent-integration-test-win-2022*",
3030
"useSSM": true
3131
},
3232
{
3333
"os": "win-2025",
34-
"instanceType":"t3a.medium",
34+
"instanceType":"t3a.large",
3535
"ami": "cloudwatch-agent-integration-test-win-2025*",
3636
"useSSM": false
3737
},
3838
{
3939
"os": "win-2025",
40-
"instanceType":"t3a.medium",
40+
"instanceType":"t3a.large",
4141
"ami": "cloudwatch-agent-integration-test-win-2025*",
4242
"useSSM": true
4343
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
[
22
{
3-
"k8sVersion": "1.31",
3+
"k8sVersion": "1.32",
44
"ami": "AL2_x86_64_GPU",
55
"terraform_dir": "terraform/eks/addon/gpu",
66
"test_dir": "./test/gpu",
77
"instanceType":"g4dn.xlarge"
88
}
9-
]
9+
]
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[
22
{
3-
"k8sVersion": "1.31",
3+
"k8sVersion": "1.32",
44
"ami": "AL2_x86_64",
55
"instanceType":"t3.medium",
66
"arc": "amd64"
77
},
88
{
9-
"k8sVersion": "1.31",
9+
"k8sVersion": "1.32",
1010
"ami": "AL2_ARM_64",
1111
"instanceType":"m6g.large",
1212
"arc": "arm64"
1313
}
14-
]
14+
]
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[
22
{
3-
"k8sVersion": "1.31"
3+
"k8sVersion": "1.32"
44
}
5-
]
5+
]

0 commit comments

Comments
 (0)