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

Add custom vpc support in AWS cloud prepare #1007

Merged
merged 1 commit into from
Sep 25, 2024

Conversation

aswinsuryan
Copy link
Contributor

Add custom vpc support in AWS cloud prepare

@submariner-bot
Copy link
Contributor

🤖 Created branch: z_pr1007/aswinsuryan/aws-custom-vpc

@aswinsuryan aswinsuryan force-pushed the aws-custom-vpc branch 22 times, most recently from 4fd622e to 00c4f51 Compare September 24, 2024 16:18
@aswinsuryan aswinsuryan marked this pull request as ready for review September 24, 2024 16:36
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
out.txt Outdated
@@ -0,0 +1,443 @@
/*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume you didn't mean to submit this file.

pkg/aws/aws.go Outdated
type awsCloud struct {
client awsClient.Interface
infraID string
region string
nodeSGSuffix string
controlPlaneSGSuffix string
CloudConfig map[string]interface{}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't need to be public for consistency.

Suggested change
CloudConfig map[string]interface{}
cloudConfig map[string]interface{}

publicSubnets, err = d.aws.findPublicSubnets(vpcID, d.aws.filterByName("{infraID}*-public-{region}*"))
if err != nil {
return status.Error(err, "unable to find public subnets")
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This code block looks the same as the block starting on L152 above except the latter checks for len(publicSubnets). I think we can refactor to a function and let the caller check len(publicSubnets).

Comment on lines 119 to 124
err = d.processSubnets(vpcID, gatewaySG, publicSubnets, input, status)
if err != nil {
return err
}

return nil
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
err = d.processSubnets(vpcID, gatewaySG, publicSubnets, input, status)
if err != nil {
return err
}
return nil
return d.processSubnets(vpcID, gatewaySG, publicSubnets, input, status)

@tpantelis tpantelis merged commit e1aa569 into submariner-io:devel Sep 25, 2024
15 checks passed
@submariner-bot
Copy link
Contributor

🤖 Closed branches: [z_pr1007/aswinsuryan/aws-custom-vpc]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants