Answers: <p>I don't see any documentation from serverless.com that they support C and C++ (while AWS Lambda might do), I have asked about it now so that we can know:</p>
  
  <p><a href="https://forum.serverless.com/t/c-and-c-support/8045" rel="nofollow noreferrer">https://forum.serverless.com/t/c-and-c-support/8045</a></p>
  
  <p>("Supports Node.js, Python, Java, Go, C#, Ruby, Swift, Kotlin, PHP, Scala, &amp; F#") but if you want to try then I think that you should try some other name than "function" for your function. I did not try this at home but all examples use some other name than "function" because that word might be reserved. </p>
  
  <p><a href="https://serverless.com/framework/docs/providers/aws/guide/resources/" rel="nofollow noreferrer">https://serverless.com/framework/docs/providers/aws/guide/resources/</a> </p>
  
  <p>If that still won't work, check your path to your code and maybe you also want to set up everything up with a CI/CD pipeline with GitLab for example. That's how I do it. </p>
  
Answers: CC BY-SA 4.0
Answers: 2019-04-21T13:18:28.600Z
Answers: I used a different name than "function". I have no knowledge of Gitlab CI/CD... but  I will see if it can help
Answers: romanbird
Answers: CC BY-SA 4.0
Answers: 2019-04-21T09:25:09.953Z
Answers: 2019-04-21T09:30:46.263Z
Answers: 2019-04-21T09:30:46.263Z
Answers: Niklas Rosencrantz
Body: <p>I have followed the guide in <a href="https://aws.amazon.com/blogs/compute/introducing-the-c-lambda-runtime/" rel="nofollow noreferrer">https://aws.amazon.com/blogs/compute/introducing-the-c-lambda-runtime/</a> to package my c++ lambda function into a zip file. The zip file has the contents: 
  function.zip
    bin
       function
    lib
       many .so files, etc.
    bootstrap</p>
  
  <p>In the guide the lambda is deployed using the <code>aws lambda create-function</code> with the handler specified to be the same as the zip file name.</p>
  
  <p>I would like to configure this lambda function in my serverless.yml and deploy it with the rest of my lambdas. I am not sure what the handler field below should be and using the zip file name didn't work out. </p>
  
  <pre><code>functions:  
    function:
      runtime: provided
      package:
        include: 
          - function.zip
      handler: function 
      events:
        - http:
            path: function
            method: get
            cors: true
            authorizer: aws_iam
  </code></pre>
  
  <p>When I run <code>serverless deploy -v</code> I get warnings like: </p>
  
  <blockquote>
    <p>Serverless:  WARNING: Entry for function@function could not be
    retrieved. Please check your service config if you want to use
    lib.entries.</p>
  </blockquote>
  
Tags: <aws-lambda><serverless>
Title: Serverless framework: how to specify a c++ lambda function with provided deployment package
UserDisplayName: romanbird
ThreadText: # Serverless framework: how to specify a c++ lambda function with provided deployment package
  
  (Asked by: username_0 on 2019-04-21)
  
  I have followed the guide in <https://aws.amazon.com/blogs/compute/introducing-the-c-lambda-runtime/> to package my c++ lambda function into a zip file. The zip file has the contents:
  function.zip
  bin
  function
  lib
  many .so files, etc.
  bootstrap
  
  In the guide the lambda is deployed using the `aws lambda create-function` with the handler specified to be the same as the zip file name.
  
  I would like to configure this lambda function in my serverless.yml and deploy it with the rest of my lambdas. I am not sure what the handler field below should be and using the zip file name didn't work out.
  
  ```
  functions:  
    function:
      runtime: provided
      package:
        include: 
          - function.zip
      handler: function 
      events:
        - http:
            path: function
            method: get
            cors: true
            authorizer: aws_iam
  
  ```
  
  When I run `serverless deploy -v` I get warnings like:
  
  > Serverless: WARNING: Entry for function@function could not be
  > retrieved. Please check your service config if you want to use
  > lib.entries.
  
  **Tags:** aws-lambda, serverless
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-04-21. Score: 1
  
  I don't see any documentation from serverless.com that they support C and C++ (while AWS Lambda might do), I have asked about it now so that we can know:
  
  <https://forum.serverless.com/t/c-and-c-support/8045>
  
  ("Supports Node.js, Python, Java, Go, C#, Ruby, Swift, Kotlin, PHP, Scala, & F#") but if you want to try then I think that you should try some other name than "function" for your function. I did not try this at home but all examples use some other name than "function" because that word might be reserved.
  
  <https://serverless.com/framework/docs/providers/aws/guide/resources/>
  
  If that still won't work, check your path to your code and maybe you also want to set up everything up with a CI/CD pipeline with GitLab for example. That's how I do it.
  
  > **Comments:**
  > **username_0**: I used a different name than "function". I have no knowledge of Gitlab CI/CD... but  I will see if it can help  
  
  ---
  
  