Lambda Run Remote - Runtime.InvalidEntrypoint

I've created a new project from a template HelloWorld. I use Rider and macOS. When I build the image with local configuration, the image is created successfully. 


When I run the remote configuration I receive Runtime.InvalidEntrypoint


This is how my default template.yaml file looks like.

AWSTemplateFormatVersion: '2010-09-09'
Transform: AWS::Serverless-2016-10-31
Description: >
  Sample SAM Template for HelloWorld

# More info about Globals:
    Timeout: 10
    MemorySize: 128

    Type: AWS::Serverless::Function # More info about Function Resource:
      PackageType: Image
          Type: Api # More info about API Event Source:
            Path: /hello
            Method: get
      DockerTag: dotnet6-v1
      DockerContext: ./src/HelloWorld
      Dockerfile: Dockerfile
        SAM_BUILD_MODE: run

  # ServerlessRestApi is an implicit API created out of Events key under Serverless::Function
  # Find out more about other implicit resources you can reference within SAM
    Description: "API Gateway endpoint URL for Prod stage for Hello World function"
    Value: !Sub "https://${ServerlessRestApi}.execute-api.${AWS::Region}"
    Description: "Hello World Lambda Function ARN"
    Value: !GetAtt HelloWorldFunction.Arn
    Description: "Implicit IAM Role created for Hello World function"
    Value: !GetAtt HelloWorldFunctionRole.Arn


This is what my Remote configuration looks like. 


I use macOS and I read that Runtime.InvalidEntrypoint is thrown when the image is built with a different architecture type than expected which makes sense. macOS default configuration is arm64 and I guess lambda is expecting x86/64. 
If that's the case, how to set up the remote configuration so that the output is x64 image?

1 comment
Comment actions Permalink


Thank you for reaching Rider Forum.

I tried reproducing your issue on my Mac M1, however, I could run the Remote configuration with no issues. Also, InvalidEntrypoint error can occur because of the path settings, according to the documentation of the Amazon.

Thus, I'd like to check log files first in order to narrow down potential misconfiguration. Could you please reproduce the issue and collect the full log bundle so we could take a closer look at the case? Please upload logs to and provide me with the file(s) ID. 

Thank you in advance! Looking forward to hearing from you soon.


Please sign in to leave a comment.