aws lambda create-function --function-name aws-codebuild-python-lambda \
--runtime python3.8 \
--handler lambda_handler \
--role arn:aws:iam::your-account-id:role/YourLambdaExecutionRole \
--zip-file fileb://your-lambda-deployment-package.zip
aws iam create-role --role-name YourLambdaExecutionRole --assume-role-policy-document file://lambda-execution-trust-policy.json
aws iam put-role-policy --role-name YourLambdaExecutionRole --policy-name LambdaExecutionPolicy --policy-document file://lambda-execution-policy.json
aws iam update-assume-role-policy --role-name YourLambdaExecutionRole --policy-document file://lambda-execution-trust-policy.json
aws iam create-policy --policy-name AWSCodeBuild_CloudWatchLogs --policy-document file://aws_code_build_cloudwatch_logs.json
aws iam create-role --role-name AWS_CODEBUILD_SERVICE_ROLE --assume-role-policy-document '{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"Service": "codebuild.amazonaws.com"
},
"Action": "sts:AssumeRole"
}
]
}'
AWSCodeBuild_CloudWatchLogs policy
aws iam attach-role-policy --role-name AWS_CODEBUILD_SERVICE_ROLE --policy-arn arn:aws:iam::aws:policy/service-role/AWSCodeBuild_CloudWatchLogs
aws codebuild create-project --cli-input-json file://codebuild-project.json
aws codebuild start-build --project-name aws-codebuild-python-lambda
-
Notifications
You must be signed in to change notification settings - Fork 0
OmprakashPaliwal/aws-codebuild-python-lambda
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published