diff --git a/src/e3/aws/troposphere/ec2/__init__.py b/src/e3/aws/troposphere/ec2/__init__.py index 6a505ec4..48853dda 100644 --- a/src/e3/aws/troposphere/ec2/__init__.py +++ b/src/e3/aws/troposphere/ec2/__init__.py @@ -222,7 +222,7 @@ def interface_vpc_endpoints(self) -> list[ec2.VPCEndpoint]: endpoints.append( ec2.VPCEndpoint( - name_to_id(f"{service_name}Endpoint"), + name_to_id(f"{self.vpc.name}-{service_name}Endpoint"), PrivateDnsEnabled="true", SecurityGroupIds=[security_group_id], ServiceName=f"com.amazonaws.{self.region}.{service_name}", diff --git a/tests/tests_e3_aws/troposphere/ec2/vpc.json b/tests/tests_e3_aws/troposphere/ec2/vpc.json index d5e256b9..6caf23d1 100644 --- a/tests/tests_e3_aws/troposphere/ec2/vpc.json +++ b/tests/tests_e3_aws/troposphere/ec2/vpc.json @@ -242,7 +242,7 @@ }, "Type": "AWS::EC2::SecurityGroupIngress" }, - "LogsEndpoint": { + "TestVPCLogsEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -278,7 +278,7 @@ }, "Type": "AWS::EC2::VPCEndpoint" }, - "EcrapiEndpoint": { + "TestVPCEcrapiEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -314,7 +314,7 @@ }, "Type": "AWS::EC2::VPCEndpoint" }, - "EcrdkrEndpoint": { + "TestVPCEcrdkrEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -350,7 +350,7 @@ }, "Type": "AWS::EC2::VPCEndpoint" }, - "StsEndpoint": { + "TestVPCStsEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -371,7 +371,7 @@ }, "Type": "AWS::EC2::VPCEndpoint" }, - "SecretsmanagerEndpoint": { + "TestVPCSecretsmanagerEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -501,4 +501,4 @@ }, "Type": "AWS::EC2::SecurityGroup" } -} \ No newline at end of file +} diff --git a/tests/tests_e3_aws/troposphere/ec2/vpc_ses_and_other_endpoints.json b/tests/tests_e3_aws/troposphere/ec2/vpc_ses_and_other_endpoints.json index f38b3cd9..2080e5fa 100644 --- a/tests/tests_e3_aws/troposphere/ec2/vpc_ses_and_other_endpoints.json +++ b/tests/tests_e3_aws/troposphere/ec2/vpc_ses_and_other_endpoints.json @@ -242,7 +242,7 @@ }, "Type": "AWS::EC2::SecurityGroupIngress" }, - "EmailSmtpEndpoint": { + "TestVPCEmailSmtpEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -263,7 +263,7 @@ }, "Type": "AWS::EC2::VPCEndpoint" }, - "LogsEndpoint": { + "TestVPCLogsEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ @@ -284,7 +284,7 @@ }, "Type": "AWS::EC2::VPCEndpoint" }, - "StsEndpoint": { + "TestVPCStsEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [ diff --git a/tests/tests_e3_aws/troposphere/ec2/vpc_ses_endpoint.json b/tests/tests_e3_aws/troposphere/ec2/vpc_ses_endpoint.json index e4dcd1a1..a42fcfe5 100644 --- a/tests/tests_e3_aws/troposphere/ec2/vpc_ses_endpoint.json +++ b/tests/tests_e3_aws/troposphere/ec2/vpc_ses_endpoint.json @@ -242,7 +242,7 @@ }, "Type": "AWS::EC2::SecurityGroupIngress" }, - "EmailSmtpEndpoint": { + "TestVPCEmailSmtpEndpoint": { "Properties": { "PrivateDnsEnabled": true, "SecurityGroupIds": [