MCPcopy Index your code

hub / github.com/awslabs/cfn-ecr-aws-soci-index-builder / functions

Functions36 in github.com/awslabs/cfn-ecr-aws-soci-index-builder

↓ 18 callersFunctionlog_and_generate_response
(status_code, message)
functions/source/ecr-image-action-event-filtering/ecr_image_action_event_filtering_lambda_function.py:116
↓ 7 callersFunctionlambdaError
Log and return the lambda handler error
functions/source/soci-index-generator-lambda/handler.go:375
↓ 3 callersFunctionaddContext
Add more context to the log event
functions/source/soci-index-generator-lambda/utils/log/log.go:34
↓ 2 callersMethodGetManifest
Call registry's getManifest and return the image's manifest The image reference must be a digest because that's what oras-go FetchReference takes
functions/source/soci-index-generator-lambda/utils/registry/registry.go:136
↓ 2 callersFunctionHandleRequest
(ctx context.Context, event events.ECRImageActionEvent)
functions/source/soci-index-generator-lambda/handler.go:64
↓ 2 callersMethodHeadManifest
Call registry's headManifest and return the manifest's descriptor
functions/source/soci-index-generator-lambda/utils/registry/registry.go:120
↓ 2 callersFunctionInit
Initialize a remote registry
functions/source/soci-index-generator-lambda/utils/registry/registry.go:53
↓ 2 callersFunctioncleanUp
Clean up the data written by the Lambda
functions/source/soci-index-generator-lambda/handler.go:256
↓ 2 callersFunctionlog_to_cloudwatch
(message)
functions/source/ecr-image-action-event-filtering/ecr_image_action_event_filtering_lambda_function.py:124
↓ 2 callersMethodvalidateImageManifest
(ctx context.Context, repositoryName string, digest string)
functions/source/soci-index-generator-lambda/utils/registry/registry.go:161
↓ 1 callersFunctionCalculateFreeSpace
Calculate free splace in bytes of a directory
functions/source/soci-index-generator-lambda/utils/fs/fs.go:10
↓ 1 callersMethodPull
Pull an image from the remote registry to a local OCI Store imageReference can be either a digest or a tag
functions/source/soci-index-generator-lambda/utils/registry/registry.go:70
↓ 1 callersMethodPush
Push a OCI artifact to remote registry descriptor: ocispec Descriptor of the artifact ociStore: the local OCI store tag: optional tag to apply to the
functions/source/soci-index-generator-lambda/utils/registry/registry.go:89
↓ 1 callersMethodValidateImageDigest
ValidateImageDigest validates if a digest is valid based on SOCI index version requirements For SOCI V1, only image manifests are supported For SOCI V
functions/source/soci-index-generator-lambda/utils/registry/registry.go:199
↓ 1 callersFunctionauthorizeEcr
Authorize ECR registry
functions/source/soci-index-generator-lambda/utils/registry/registry.go:234
↓ 1 callersFunctionbuildEcrRegistryUrl
Returns ecr registry url from an image action event
functions/source/soci-index-generator-lambda/handler.go:230
↓ 1 callersFunctionbuildIndex
Build soci index for an image and returns its ocispec.Descriptor
functions/source/soci-index-generator-lambda/handler.go:315
↓ 1 callersFunctioncreateTempDir
Create a temp directory in /tmp The directory is prefixed by the Lambda's request id
functions/source/soci-index-generator-lambda/handler.go:240
↓ 1 callersFunctioninitContainerdStore
Init containerd store
functions/source/soci-index-generator-lambda/handler.go:288
↓ 1 callersFunctioninitSociArtifactsDb
Init a new instance of SOCI artifacts DB
functions/source/soci-index-generator-lambda/handler.go:305
↓ 1 callersFunctioninitSociStore
Init SOCI artifact store
functions/source/soci-index-generator-lambda/handler.go:294
↓ 1 callersFunctionisEcrRegistry
Check if a registry is an ECR registry
functions/source/soci-index-generator-lambda/utils/registry/registry.go:224
↓ 1 callersFunctionsetDeadline
Set up deadline for the lambda to proactively clean up its data before the invocation timeout. We don't want to keep data in storage when the Lambda r
functions/source/soci-index-generator-lambda/handler.go:267
↓ 1 callersFunctionvalidateEvent
Validate the given event, populating the context with relevant valid event properties
functions/source/soci-index-generator-lambda/handler.go:156
↓ 1 callersMethodvalidateImageIndex
(ctx context.Context, repositoryName string, digest string)
functions/source/soci-index-generator-lambda/utils/registry/registry.go:181
↓ 1 callersFunctionvalidate_event
(event)
functions/source/ecr-image-action-event-filtering/ecr_image_action_event_filtering_lambda_function.py:79
FunctionError
(ctx context.Context, msg string, err error)
functions/source/soci-index-generator-lambda/utils/log/log.go:15
FunctionInfo
(ctx context.Context, msg string)
functions/source/soci-index-generator-lambda/utils/log/log.go:27
FunctionTestGetFreeSpace
(t *testing.T)
functions/source/soci-index-generator-lambda/utils/fs/fs_test.go:8
FunctionTestGetManifest
(t *testing.T)
functions/source/soci-index-generator-lambda/utils/registry/registry_test.go:68
FunctionTestHandlerHappyPath
This test ensures that the handler can pull Docker and OCI images, build, and push the SOCI index back to the repository. To run this test locally, yo
functions/source/soci-index-generator-lambda/handler_test.go:23
FunctionTestHandlerInvalidDigestMediaType
This test ensures that the handler can validate the input digest media type To run this test locally, you need to push an image to a private ECR repos
functions/source/soci-index-generator-lambda/handler_test.go:83
FunctionTestHeadManifest
(t *testing.T)
functions/source/soci-index-generator-lambda/utils/registry/registry_test.go:19
FunctionWarn
(ctx context.Context, msg string)
functions/source/soci-index-generator-lambda/utils/log/log.go:21
Functionlambda_handler
Handler - Meant to be invoked by EventBridge for ECR Image Action events. sample event data from EventBridge: { "version
functions/source/ecr-image-action-event-filtering/ecr_image_action_event_filtering_lambda_function.py:11
Functionmain
()
functions/source/soci-index-generator-lambda/handler.go:380