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

Cloudformation stackset creates instance in default VPC #556

Open
Chan9390 opened this issue Sep 19, 2023 · 3 comments
Open

Cloudformation stackset creates instance in default VPC #556

Chan9390 opened this issue Sep 19, 2023 · 3 comments

Comments

@Chan9390
Copy link

While self deploying metlo on custom VPC, the cloudformation stackset fails.

The reason is MetloSecurityGroup is created in a VPC provided in parameters however the MetloInstance doesnt consider the VPC parameter and creates in a default VPC.

So the stackset fails due to the following error and rolls back:

Security group sg-xxxxxxxxxxx and subnet subnet-yyyyyyyyyyyyy belong to different networks. (Service: AmazonEC2; Status Code: 400; Error Code: InvalidParameter; Request ID: aaa-bbb-ccc; Proxy: null)

@Chan9390
Copy link
Author

I used the cloudformation script provided at https://my.metlo.com/ after signup

@akshay288
Copy link
Contributor

Hey @Chan9390 sorry about that! Fixing ASAP

@Chan9390
Copy link
Author

Heres the fix that worked for me:

Add a network interface instead of security group id:

                "NetworkInterfaces": [
                    {
                        "AssociatePublicIpAddress": "true",
                        "DeviceIndex": "0",
                        "GroupSet": [
                            {
                                "Ref" : "MetloSecurityGroup"
                            }
                        ],
                        "SubnetId": {
                            "Ref" : "SubnetId"
                        }
                    }
                ],

And add the subnet id in parameters.

As the cloudformation script for Metlo collector is not maintained in any public GitHub repo, I wasnt able to raise PR.

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

No branches or pull requests

2 participants