You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lambda-elastic-ip-no-nat-gateway-cdk/README.md
+11-30Lines changed: 11 additions & 30 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,11 +1,12 @@
1
-
# Lambda Elastic IP without NAT Gateway
1
+
# AWS Lambda Elastic IP without NAT Gateway
2
2
3
3
This project contains a sample AWS Cloud Development Kit (AWS CDK) template for deploying a Lambda function with a public elastic IP that has internet access without the need to provision a NAT gateway.
6. Note: The AWS CDK deployment process will output the DynamoDB table name, the API endpoint, and the IoT Core Topic name used for testing this project
69
-
70
52
71
53
## Use Case
72
-
You have a lambda function that requires internet access to make api calls to 3rd party vendors but you need a dedicated IP to be whitelisted by the 3rd party vendors.
54
+
You have a Lambda function that requires internet access to make API calls to 3rd party service but you need a dedicated IP to be whitelisted by the 3rd party vendors.
55
+
73
56
## How it works
74
57
75
-
This pattern allows you to assign your lambda function a static public IP address that you can use to interact with APIs that require whitelisted IPs without the need to provision a NAT Gateway. Therefore, this pattern will save almost **$33/month** in NAT Gateway costs.
58
+
This pattern allows you to assign your Lambda function a static public IP address that you can use to interact with APIs that require whitelisted IPs without the need to provision a NAT Gateway. Therefore, this pattern will save almost **$33/month** in NAT Gateway costs.
76
59
60
+
##### **NOTE:** This pattern is best suited for non-production environments since it is not multi-AZ nor highly scalable.
77
61
78
62
The following resources will be provisioned:
79
63
@@ -83,19 +67,16 @@ The following resources will be provisioned:
83
67
84
68
Since AWS manages the provisioning of any Lambda ENI, we cannot access that ENI in CDK code. Therefore, to automate the process, we have to associate the Elastic IP with the ENI in a custom resource after the deployment occurs and the ENI is provisioned.
85
69
86
-
##### **NOTE:** This pattern is best suited for non-production environments since it is not multi-AZ nor highly scalable.
87
-
88
70
## Testing
89
71
90
-
To test this pattern, you must use both the AWS Console and the AWS CLI.
72
+
To test this pattern, use the AWS Console or the AWS CLI.
91
73
92
74
### AWS Console Part
93
75
94
76
1. Open the AWS Lambda Console
95
77
2. Navigate to `vin-api-lambda`
96
78
3. Test the lambda with any payload
97
-
4. The lambda shouldn't time out and a random vin should be returned and logged.
98
-
79
+
4. The Lambda function shouldn't time out and a random vin should be returned and logged.
0 commit comments