aws_lambda: cdk synth/deploy not working with lambda packaging on linux/arm64 #21984
Labels
@aws-cdk/aws-lambda
Related to AWS Lambda
bug
This issue is a bug.
effort/small
Small work item – less than a day of effort
p2
Describe the bug
Attempting to run
cdk synth
/cdk deploy
on Fedora Linux 36 on ARM64 with a Lambda function and with Docker Engine (not Desktop) installed, results in the error:Attempting to run docker with the image used (gleaned from
docker --debug
is fine:But I have narrowed the issue down to the fact that specifying a uid/gid (which the cdk does) reproduces the error:
Expected Behavior
cdk synth
andcdk deploy
should work just fine on linux/arm64.Current Behavior
The cdk specifies the uid/gid of the user as part of synth and deploy to execute the docker container. However, this fails with:
Reproduction Steps
With the CDK develop an app stack that includes a Lambda definition like below on Fedora Linux 36 with Docker Enginer (not Desktop, which is not available on Linux/ARM64) installed.
Possible Solution
Unsure. As we know that running the docker container without specifying uid/gid (so, root) I guess doing so as part of the cdk would be one (perhaps insecure) workaround.
Additional Information/Context
This is a problem that I have reproduced at least from cdk version >= 2.38.0 and up.
CDK CLI Version
2.41.0 (build 6ad48a3)
Framework Version
No response
Node.js Version
v16.16.0
OS
Linux fedora 5.19.6-200.fc36.aarch64 #1 SMP PREEMPT_DYNAMIC Wed Aug 31 16:40:17 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
(Parallels VM on MacOS 12.5.1)
Language
Python
Language Version
Python 3.10.6
Other information
No response
The text was updated successfully, but these errors were encountered: