generated from MITLibraries/python-lambda-template
-
Notifications
You must be signed in to change notification settings - Fork 0
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
Dev Workflows for Lambda@Edge #2
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Why these changes are being introduced: We need to different dev workflows, one that just redeploys the CloudFront distribution without pushing a zip from GitHub and one that performs the full Lambda function upload and CloudFront redeployment. How this addresses that need: * Update Makefile with manual zip deployment commands * Add a workflow_dispatch GHA workflow for dev that only redeploys the CloudFront distribution (by triggering a plan/apply in TfC) * Add a workflow_dispatch GHA workflow for dev that handles the full zip upload and CloudFront distribution redeploy Side effects of this change: None. Relevant ticket(s): * https://mitlibraries.atlassian.net/browse/GDT-97
9ccfaba
to
a9003d4
Compare
Pull Request Test Coverage Report for Build 7492088323
💛 - Coveralls |
Why these changes are being introduced: With the new shared workflows now in the main branch of the .github repository, the final versions of the caller workflow (generated from the TfC outputs of the mitlib-tf-workloads-libraries-website repo) can be put in place here. How this addresses that need: * Update Makefile with new `create-zip` and `upload-zip` commands * Update the caller workflows to match the shared workflows in the .github repository * Update the README Side effects of this change: None. Relevant ticket(s): * https://mitlibraries.atlassian.net/browse/GDT-97
c45b971
to
d16d40a
Compare
JPrevost
reviewed
Jan 11, 2024
Why these changes are being introduced: Per the conversations in the PR, there were a few tweaks so the in-line comments in some files. How this addresses that need: * Correct the comment at the top of each of the dev GHA workflows * Update the PR template Side effects of this change: None.
@JPrevost thanks for the feedback! I just pushed up the requested tweaks. |
JPrevost
approved these changes
Jan 11, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there remain a files in this repo that should we should consider whether they add value or noise, but that is outside the scope of this work.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose and background context
This is part of a Proof-of-Concept for determining how to publish Lambda@Edge functions from application repositories to our Terraform-managed CloudFront distributions. In this round of changes, the caller workflows are cleaned up and use the new shared workflows that have been merged to the
main
branch of the .github repository.We need two different dev workflows, one that just redeploys the CloudFront distribution without pushing a zip from GitHub and one that performs the full Lambda function upload and CloudFront redeployment. We also include a stage workflow with the automation temporarily disabled.
How this addresses that need
create-zip
andupload-zip
)How can a reviewer manually see the effects of these changes?
With all the changes, it is not possible to test the GHA workflows at this time. Multiple tests have been done and can be found in the Actions history on this repo.
Test the
make
commandsCheckout this branch locally. Authenticate to Dev1 (as a full admin user) on the command line and then run
make create-zip
. This should zip up the code for the Lambda function. Runmake upload-zip
. This should copy the .zip file to the S3 bucket in Dev1. In the AWS Console, you can navigate to theshared-files-xxxx
S3 bucket and open thefiles/
folder and see the that Last Modified date on thecf-lambda-custom-domain.py.zip
file has updated.Includes new or updated dependencies?
YES: This depends on a new shared workflow in our .github repo. See PR#49 for more details about that shared workflow.
Changes expectations for external applications?
NO
What are the relevant tickets?
Developer
Code Reviewer(s)