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

Clean up the old versions of the redirect Lambdas #19

Open
alexwlchan opened this issue Sep 17, 2022 · 2 comments
Open

Clean up the old versions of the redirect Lambdas #19

alexwlchan opened this issue Sep 17, 2022 · 2 comments

Comments

@alexwlchan
Copy link
Contributor

We've had an email from AWS:

We are contacting you as we have identified that your AWS Account currently has one or more Lambda functions using Node.js 12 runtime.

We are ending support for Node.js 12 in AWS Lambda. This follows Node.js 12 End-Of-Life (EOL) reached on April 30, 2022.

If you run the command they specify, you discover that all the affected Lambda functions are old versions of the redirect Lambda from this repository:

Counter({'arn:aws:lambda:us-east-1:760097843905:function:cf_edge_wellcome_library_redirect': 93,
         'arn:aws:lambda:us-east-1:760097843905:function:cf_edge_wellcome_library_passthru': 74,
         'arn:aws:lambda:us-east-1:760097843905:function:cf_edge_wellcome_library_blog_redirect': 58,
         'arn:aws:lambda:us-east-1:760097843905:function:cf_edge_wellcome_library_archive_redirect': 41,
         'arn:aws:lambda:us-east-1:760097843905:function:cf_edge_wellcome_library_encore_redirect': 38,
         'arn:aws:lambda:us-east-1:760097843905:function:cf_edge_dlcs_path_rewrite': 24})

We're using Node 16 for all the current versions (see bce1d1b), so nothing is going to break when Node.js 12 goes EOL – but we don't need these old versions, so we should clean them up so we don't get any more warnings from AWS.

@alexwlchan
Copy link
Contributor Author

I forgot to write down the command, which is:

aws lambda list-functions --function-version ALL $ env AWS_PROFILE=platform-dev aws lambda list-functions --function-version ALL --region us-east-1 --output text --query "Functions[?Runtime=='nodejs12.x'].FunctionArn"

@alexwlchan alexwlchan moved this from Backlog to In Progress in Digital platform Oct 31, 2022
@alexwlchan alexwlchan self-assigned this Oct 31, 2022
@alexwlchan
Copy link
Contributor Author

Okay, so it turns out to be a bit more complicated – the cf_edge_dlcs_path_write Lambda is still running a Nodejs 12.x runtime, so we can't delete it. That lives in a separate repo, so I'll open a ticket for that.

@alexwlchan alexwlchan moved this from In Progress to Ready for review in Digital platform Oct 31, 2022
@alexwlchan alexwlchan moved this from Ready for review to Backlog in Digital platform Oct 31, 2022
@alexwlchan alexwlchan removed their assignment Oct 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Backlog
Development

No branches or pull requests

1 participant