Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change the ec2 instance ami to AL2 #139

Merged
merged 1 commit into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions lib/infra/infra-stack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -495,11 +495,11 @@
);
}
if (this.singleNodeCluster) {
console.log('Single node value is true, creating single node configurations');

Check warning on line 498 in lib/infra/infra-stack.ts

View workflow job for this annotation

GitHub Actions / build

Unexpected console statement
singleNodeInstance = new Instance(this, 'single-node-instance', {
vpc: props.vpc,
instanceType: singleNodeInstanceType,
machineImage: MachineImage.latestAmazonLinux2023(
machineImage: MachineImage.latestAmazonLinux2(
{
cpuType: instanceCpuType,
},
Expand Down Expand Up @@ -561,7 +561,7 @@
const managerNodeAsg = new AutoScalingGroup(this, 'managerNodeAsg', {
launchTemplate: new LaunchTemplate(this, 'managerNodeLt', {
instanceType: defaultInstanceType,
machineImage: MachineImage.latestAmazonLinux2023({
machineImage: MachineImage.latestAmazonLinux2({
cpuType: instanceCpuType,
}),
role: this.instanceRole,
Expand Down Expand Up @@ -600,7 +600,7 @@
const seedNodeAsg = new AutoScalingGroup(this, 'seedNodeAsg', {
launchTemplate: new LaunchTemplate(this, 'seedNodeLt', {
instanceType: (seedConfig === 'seed-manager') ? defaultInstanceType : this.dataInstanceType,
machineImage: MachineImage.latestAmazonLinux2023({
machineImage: MachineImage.latestAmazonLinux2({
cpuType: instanceCpuType,
}),
role: this.instanceRole,
Expand Down Expand Up @@ -641,7 +641,7 @@
const dataNodeAsg = new AutoScalingGroup(this, 'dataNodeAsg', {
launchTemplate: new LaunchTemplate(this, 'dataNodeLt', {
instanceType: this.dataInstanceType,
machineImage: MachineImage.latestAmazonLinux2023({
machineImage: MachineImage.latestAmazonLinux2({
cpuType: instanceCpuType,
}),
role: this.instanceRole,
Expand Down Expand Up @@ -678,7 +678,7 @@
clientNodeAsg = new AutoScalingGroup(this, 'clientNodeAsg', {
launchTemplate: new LaunchTemplate(this, 'clientNodelt', {
instanceType: defaultInstanceType,
machineImage: MachineImage.latestAmazonLinux2023({
machineImage: MachineImage.latestAmazonLinux2({
cpuType: instanceCpuType,
}),
role: this.instanceRole,
Expand Down Expand Up @@ -716,7 +716,7 @@
const mlNodeAsg = new AutoScalingGroup(this, 'mlNodeAsg', {
launchTemplate: new LaunchTemplate(this, 'mlNodeLt', {
instanceType: this.mlInstanceType,
machineImage: MachineImage.latestAmazonLinux2023({
machineImage: MachineImage.latestAmazonLinux2({
cpuType: instanceCpuType,
}),
role: this.instanceRole,
Expand Down
6 changes: 2 additions & 4 deletions test/infra-stack-props.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ test('Throw error on incorrect JSON for opensearch', () => {
} catch (error) {
expect(error).toBeInstanceOf(Error);
// @ts-ignore
expect(error.message).toEqual('Encountered following error while parsing additionalConfig json parameter: '
+ 'SyntaxError: Unexpected token e in JSON at position 33');
expect(error.message).toContain('Encountered following error while parsing additionalConfig json parameter:');
}
});

Expand Down Expand Up @@ -84,8 +83,7 @@ test('Throw error on incorrect JSON for opensearch-dashboards', () => {
} catch (error) {
expect(error).toBeInstanceOf(Error);
// @ts-ignore
expect(error.message).toEqual('Encountered following error while parsing additionalOsdConfig json parameter: '
+ 'SyntaxError: Unexpected token s in JSON at position 31');
expect(error.message).toContain('Encountered following error while parsing additionalOsdConfig json parameter:');
}
});

Expand Down
3 changes: 1 addition & 2 deletions test/opensearch-cluster-cdk.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -777,8 +777,7 @@ test('Throw error on incorrect JSON', () => {
} catch (error) {
expect(error).toBeInstanceOf(Error);
// @ts-ignore
expect(error.message).toEqual('Encountered following error while parsing customConfigFiles json parameter: '
+ 'SyntaxError: Unexpected token o in JSON at position 25');
expect(error.message).toContain('Encountered following error while parsing customConfigFiles json parameter:');
}
});

Expand Down
Loading