Skip to content
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

### Is there an existing issue for this? #11

Open
1 task done
iambary44 opened this issue Oct 13, 2023 · 0 comments
Open
1 task done

### Is there an existing issue for this? #11

iambary44 opened this issue Oct 13, 2023 · 0 comments

Comments

@iambary44
Copy link
Member

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

Performing the steps below will not give an error message when the lambda fails to create.

create-function expectedly returns 201 because async operation, but then when adding bucket notifications we will get a 400 and also a message that the docker socket is not mounted.

If run with DEBUG=1 we see that the lambda function fails to create because it can not pull the initial container image, but this error is not exposed without DEBUG.

All this can be avoided by pushing a container before creating lambdas, but I was hoping to do all my initialization hands-free.

If docker client CLI were included in the pro image I would probably download and push a hello-world image to the repo after creation.

Expected Behavior

When the lambda fails to create, raise an error outside of DEBUG mode.

Also do not raise error that docker socket is not mounted because this is incorrect/misleading information.

How are you starting LocalStack?

With a docker-compose file

Steps To Reproduce

How are you starting localstack (e.g., bin/localstack command, arguments, or docker-compose.yml)

docker compose with mounted docker socket

Client commands (e.g., AWS SDK code snippet, or sequence of "awslocal" commands)

awslocal s3api create-bucket xyz
awslocal ecr create-repository xyz

awslocal lambda create-function \
  --function-name xyz \
  --role arn:aws:iam::112233445566:role/irrelevant \
  --code ImageUri=localhost.localstack.cloud:4510/xyz:latest \
  --timeout 120 \
  --memory-size 1024 \
  --package-type Image

awslocal s3api put-bucket-notification-configuration --bucket "xyz" --notification-configuration file://xyz-bucket-to-function.json

Environment

- OS: Mac
- LocalStack: 2.3.1-pro

Anything else?

No response

Originally posted by @kevcube in localstack/localstack#9322

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant