Skip to content

Commit

Permalink
Update deployment configuration for lambda service
Browse files Browse the repository at this point in the history
The deployment configuration for the lambda service has been updated. The changes include modifying the Dockerfile, updating the Kubernetes YAML file with proper values, and adjusting the GitHub workflow file to replace the Docker image tag using the full Git SHA instead of the first 8 characters.
  • Loading branch information
timam committed May 16, 2024
1 parent 36d0771 commit b8b63e8
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ jobs:
- name: Replace the Docker image tag with Git SHA in deploy.yaml
run: |
export GIT_SHA=$(echo $GITHUB_SHA | cut -c1-8)
sed -i "s/:.*/:$GIT_SHA/" demo/lambda/deployment/deploy.yaml
GIT_SHA=$GITHUB_SHA
sed -i.bak "s#demo-awscd-2024:.*#demo-awscd-2024:$GIT_SHA#g" demo/lambda/deployment/deploy.yaml
- name: Add & Commit changes
uses: EndBug/add-and-commit@v9
Expand Down
26 changes: 13 additions & 13 deletions demo/lambda/deployment/deploy.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
apiVersion:5c786852
kind:5c786852
metadata:5c786852
name:5c786852
annotations:5c786852
services.k8s.aws/region:5c786852
spec:5c786852
name:5c786852
packageType:5c786852
code:5c786852
imageURI:5c786852
role:5c786852
description:5c786852
apiVersion: lambda.services.k8s.aws/v1alpha1
kind: Function
metadata:
name: demo-awscd-2024
annotations:
services.k8s.aws/region: ap-southeast-1
spec:
name: demo-awscd-2024
packageType: Image
code:
imageURI: 590184123335.dkr.ecr.ap-southeast-1.amazonaws.com/demo-awscd-2024:02114c130a666742be52b1783899a35e70fd6d74
role: arn:aws:iam::590184123335:role/lambda_basic_execution
description: awscd demo lambda with ack
2 changes: 1 addition & 1 deletion demo/lambda/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ COPY app.js package.json ./

RUN npm install

CMD [ "app.handler" ]
CMD [ "app.handler" ]

0 comments on commit b8b63e8

Please sign in to comment.