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

fix: Switch lambda layers to use a region allow list for publishing #1422

Merged
merged 1 commit into from
Jan 9, 2025

Conversation

marofke
Copy link
Contributor

@marofke marofke commented Jan 9, 2025

Summary

The lambda-layers needed to have its yarn.lock file updated to build correctly.

Also, we maintain a denylist of regions that lambda layers are not published to by default, as AWS accounts do not enable new regions unless specifically subscribed. I've changed this to an allowlist instead, so we don't have to keep updating the denylist every time a new region comes out.

Testing

  • yarn clean && yarn install && yarn build
  • followed the Readme to publish lambda layers in my account, confirmed it succeeded
  • Confirmed the behaviour was the same before and after the allowlist changes:
  • Before my allowlist changes (current behaviour):
> node publish.js openssl-al2
Skipping ap-east-1
Skipping ap-south-2
Skipping cn-northwest-1
Skipping eu-south-1
Skipping me-south-1
Skipping ap-southeast-3
Skipping ap-southeast-4
Skipping cn-north-1
Skipping eu-south-2
Skipping us-gov-east-1
Skipping us-gov-west-1
Skipping ap-southeast-5
Skipping ap-southeast-7
Skipping il-central-1
Skipping af-south-1
Skipping ca-west-1
Skipping eu-central-2
Skipping me-central-1
No new version, skipping publish for us-west-2
No new version, skipping publish for us-west-1
No new version, skipping publish for us-east-2
No new version, skipping publish for ca-central-1
No new version, skipping publish for us-east-1
No new version, skipping publish for ap-northeast-3
No new version, skipping publish for ap-northeast-1
No new version, skipping publish for eu-west-1
No new version, skipping publish for ap-northeast-2
No new version, skipping publish for eu-west-2
No new version, skipping publish for eu-west-3
No new version, skipping publish for eu-central-1
No new version, skipping publish for ap-southeast-2
No new version, skipping publish for eu-north-1
No new version, skipping publish for ap-southeast-1
No new version, skipping publish for sa-east-1
No new version, skipping publish for ap-south-1
  • After my allowlist changes (new behaviour):
> node publish.js openssl-al2
Skipping ap-east-1
Skipping ap-south-2
Skipping cn-northwest-1
Skipping eu-south-1
Skipping me-south-1
Skipping ap-southeast-3
Skipping ap-southeast-4
Skipping cn-north-1
Skipping eu-south-2
Skipping us-gov-east-1
Skipping us-gov-west-1
Skipping ap-south-1
Skipping ap-southeast-5
Skipping ap-southeast-7
Skipping il-central-1
Skipping af-south-1
Skipping ca-west-1
Skipping eu-central-2
Skipping me-central-1
No new version, skipping publish for us-west-2
No new version, skipping publish for us-west-1
No new version, skipping publish for us-east-2
No new version, skipping publish for ca-central-1
No new version, skipping publish for us-east-1
No new version, skipping publish for ap-northeast-3
No new version, skipping publish for ap-northeast-1
No new version, skipping publish for eu-west-1
No new version, skipping publish for ap-northeast-2
No new version, skipping publish for eu-west-2
No new version, skipping publish for eu-west-3
No new version, skipping publish for ap-southeast-2
No new version, skipping publish for eu-central-1
No new version, skipping publish for eu-north-1
No new version, skipping publish for ap-southeast-1
No new version, skipping publish for sa-east-1

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@marofke marofke merged commit f99f868 into aws:mainline Jan 9, 2025
3 checks passed
@marofke marofke deleted the lambda-layers-region-allowlist branch January 9, 2025 17:14
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

Successfully merging this pull request may close these issues.

3 participants