Skip to content

Commit

Permalink
Update response structure in Lambda and AWS region in deploy workflow
Browse files Browse the repository at this point in the history
The response structure in Lambda's app.js has been updated by adding a comma to correctly format the returned JSON data. Also, changed the method of accessing AWS region in the deployment workflow to utilize GitHub secrets instead of environment variables for better security.
  • Loading branch information
timam committed May 16, 2024
1 parent 1ae58a7 commit 764f50f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ env.AWS_REGION }}
aws-region: ${{ secrets.AWS_REGION }}

- name: Login to Amazon ECR
id: login-ecr
Expand Down
2 changes: 1 addition & 1 deletion demo/lambda/src/app.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
exports.handler = async (event) => {
const response = {
statusCode: 200
statusCode: 200,
body: JSON.stringify('Hello from Lambda!')
};
return response;
Expand Down

0 comments on commit 764f50f

Please sign in to comment.