Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jan 16 2019 18:39

    carlosandrebp on master

    upload email icon (compare)

  • Jan 15 2019 14:03

    carlosandrebp on master

    Icons update (compare)

  • Nov 13 2018 16:54
    hassankhan commented #3
  • Nov 02 2018 15:10
    hassankhan commented #3
  • Nov 02 2018 15:10
    hassankhan commented #3
  • Nov 01 2018 23:19
    hassankhan commented #3
  • Oct 29 2018 16:32
    hassankhan commented #3
  • Oct 24 2018 14:38
    hassankhan opened #3
  • Aug 14 2018 23:50

    carlosandrebp on master

    updates animations (compare)

  • Jul 19 2018 16:34
    brianneisler closed #1
  • Jul 19 2018 16:34
    brianneisler commented #1
  • Jul 18 2018 16:36

    andrepiresbp on master

    Updates (compare)

  • Jul 18 2018 15:50

    andrepiresbp on master

    Update (compare)

  • Jul 09 2018 19:25
    gornostal commented #59
  • Jul 09 2018 19:12
    maheshmasale commented #59
  • May 24 2018 23:39
    DavidWells removed as member
  • Feb 13 2018 19:40
    ivan-myob commented #54
  • Feb 08 2018 08:48
    julien2x opened #62
  • Dec 22 2017 16:14
    awcheng opened #61
  • Oct 23 2017 19:12
    dluu2015 closed #60
chimmy-changa
@chimmy-changa

Hello Everyone,

I have recently come across container support for lambda. To my knowledge, I know that serverless framework packages/zips the code and uploads to aws. Does anyone know if serverless framework supports this container workflow ?

By container workflow I mean: When we do serverless deploy:

  • Builds docker images corresponding to the lambda functions
    • Upload to ECR
    • Create or update lambda function to use the newly uploaded container image.

Thanks in advance.

Lewis
@6ewis
what is the maximum timeout for serverless?
i put timeout: 60 but the gateway maximum seems to be 30?
chimmy-changa
@chimmy-changa
@6ewis , I believe various resources have various timeouts. functions have 15, gateway has 30.
@chimmy-changa
Lewis
@6ewis
Does anyone know the implications on cost -- with a timeout of 60s?
provider:
  name: aws
  runtime: nodejs14.x
  stage: prod
  region: us-east-1
  timeout: 60
  tracing:
    lambda: true
  environment:
    AWS_NODEJS_CONNECTION_REUSE_ENABLED: 1
naveenbalaneni
@naveenbalaneni

Unable to find the reference to layer in resource section, especially when we enable the provisionedConcurrency or functionVersion set to true.

if we remove both provisionedConcurrency or functionVersion in serverless script, same code is working fine without any issues

---
service:
  name: rtn
provider:
  name: aws
  region: us-west-2
  stackName: rtn-sls
  deploymentBucket:
    name: ${self:custom.S3BucketName.${opt:stage}}
    maxPreviousDeploymentArtifacts: 10
  deploymentPrefix: rtn/deployment
  runtime: nodejs12.x
  memorySize: 256
  timeout: 300

  # Lambda Configuration
  versionFunctions: false # Lambda Versioning

  # X-Ray Configuration
  tracing:
    lambda: true

custom:
  params: ${file(./env/${opt:stage}/parameters.json)}
  version: ${self:custom.params.Version}
  LayerVersion: ${self:custom.params.LayerVersion}
  s3Key: "https://s3.amazonaws.com/${self:custom.S3BucketName.${opt:stage}}/rtn-business-service/${self:custom.version}"

  S3BucketName:
    devint: rtn-devint
    prod: rtn

package:
  individually: true

functions:
  rtn-api-router:
    name: "rtn-api-router"
    handler: rtn-api-router.handler
    layers:
      - !Ref rtnLayer
    package:
      artifact: "${self:custom.s3Key}/rtn-api-router-v${self:custom.version}.zip"
    provisionedConcurrency: 1

resources:
  - Resources:
      rtnLayer:
        Type: AWS::Lambda::LayerVersion
        Properties:
          CompatibleRuntimes:
            - nodejs12.x
          Content:
            S3Bucket: ${self:custom.S3BucketName.${opt:stage}}
            S3Key: common-nodejs-lambda-layer/common-nodejs-lib-v${self:custom.LayerVersion}.zip
          LayerName: rtn-layer

Getting below error

Serverless Error ----------------------------------------

  ServerlessError: Could not find reference to layer: rtnLayer. Ensure that you are referencing layer defined in your service.
      at /Users/naveen/rtn-api-router/node_modules/serverless/lib/plugins/aws/package/compile/functions.js:739:15
      at Array.forEach (<anonymous>)
      at extractLayerConfigurationsFromFunction (/Users/naveen/rtn-api-router/node_modules/serverless/lib/plugins/aws/package/compile/functions.js:735:29)
      at AwsCompileFunctions.compileFunction (/Users/naveen/rtn-api-router/node_modules/serverless/lib/plugins/aws/package/compile/functions.js:458:9)
      at /Users/naveen/rtn-api-router/node_modules/serverless/lib/plugins/aws/package/compile/functions.js:680:64
      at Array.map (<anonymous>)
      at AwsCompileFunctions.compileFunctions (/Users/naveen/rtn-api-router/node_modules/serverless/lib/plugins/aws/package/compile/functions.js:680:37)
      at AwsCompileFunctions.tryCatcher (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/util.js:16:23)
      at Promise._settlePromiseFromHandler (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/promise.js:547:31)
      at Promise._settlePromise (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/promise.js:604:18)
      at Promise._settlePromise0 (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/promise.js:649:10)
      at Promise._settlePromises (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/promise.js:729:18)
      at _drainQueueStep (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/async.js:93:12)
      at _drainQueue (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/async.js:86:9)
      at Async._drainQueues (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/async.js:102:5)
      at Immediate.Async.drainQueues (/Users/naveen/rtn-api-router/node_modules/bluebird/js/release/async.js:15:14)
      at processImmediate (internal/timers.js:456:21)
tropeePatrick
@tropeePatrick

Hi all. Any serverless experts out there open to some contract work?
My startup is requiring a 3 months+ contract laying down some initial architecture and implemention in node. Fully serverless stack on AWS.
Details here:
https://docs.google.com/document/d/1bfvfRF6m8HMWuk1rGq14Q5A0Cnypx0KV6ZV4XBQToTg/edit?usp=sharing

Pm for more details
Many thanks

Akshay Kumar
@akshay-nm
Hi! I am trying to setup a few lambda functions with integration:lambda. When I do this, whatever I return from lambda gets returned as body.
Before using the integration:lambda in serverless.yml, I was using mitty to take care of cors. Does this mean that I have to pass cors related configuration in serverless.yml instead?
I have something like return { statusCode: 200, body: JSON.stringify("") } in the handler. When I inspect the response I get { statusCode: 200, body: "" } as the body of the response for the request.
I tried to go through the docs related to API Gateway Events. but I was not able to figure out how to setup functions using path and query parameters. So I switched to integration: lambda, as in this case the path and query parameters are probably automatically parsed as object and return as properties of event. But this messed up the response returned by the handlers.
Akshay Kumar
@akshay-nm
Can someone point me to a sample with integration:lambda showing the serverless.yml and the handler code?
Akshay Kumar
@akshay-nm
Sushant
@sushant_singh30_twitter
Hi all, i am new to serverless with azure and not able to find any docs for armTemplate use method in serverless.yaml
Can someone point me to any documentation they know about?
naveenbalaneni
@naveenbalaneni
Hi, is there anyway we can change lambda provisionedConcurrency based on cron schedule. Like AWS::ApplicationAutoScaling::ScalableTarget in SAM
Greg Swallow
@gswallow
I wrote a cloudformation template. Serverless insists on reading the contents of a multi-line string and pullling variables out of it.
Why?
Greg Swallow
@gswallow
seriously is there no concept of a here document in serverless?
Greg Swallow
@gswallow
Is this thing dead?
Gareth McCumskey
@garethmcc
@gswallow Could you clarify what you mean by a here document?
And can you clarigy why you would write a CloudFormation template? Serverless Framework provides you abstractions to reduce the amount of CF you need to write and then you do it directly in the serverless.yml in order to keep things together. Perhaps a little more of a description as to what it is you are trying to accomplish might help others advise on a good course of action
13colours
@13colours

Getting "EventBridge rule <rule_name> already exists" error on redeployment
I am using native CF by setting useCloudFormation: true

functions:
  eventBridge:
    handler: index.receiveEvent
    events:
      - eventBridge:
          eventBus: <ARN of the event bus>
          pattern:
            source:
          - server.name
        detail-type:
          - EVENT_NAME

Any help or guidance is much appreciated. Ty

Gareth McCumskey
@garethmcc
@13colours Can you share the ouptut of serverless --version
13colours
@13colours
@garethmcc
Framework Core: 2.53.1
Plugin: 5.4.3
SDK: 4.2.6
Components: 3.14.2
Jeremy Corson
@nexeh
Good morning. Im exploring websockets for the first time this morning using the serverless framework. looks like i got it set up and i can test using websocket king and see my logs so im pretty excited about that. Im curious how people are woprking with them in a development setting becuase it seems there is no support for cors? So if my browser based react client attempts to use it it will just error
Jake Scott
@jakejscott
Hi team, wondering when the next release is scheduled? Have a PR that we are excited to get our hands on :) serverless/serverless#9865
Gareth McCumskey
@garethmcc
@jakejscott The best bet is to tell the team that in GitHub :)
Jake Scott
@jakejscott
Cool thanks @garethmcc
Miguel Carvajal
@krvajal
does anyone has used 'serverless' as a library instead of a CLI app?
chetan.nandrajog
@steel119
Hey. Does any know of good serverless-nodejs-typescript starter production project (Even javascript will be okay) ?
I am looking for production best practices examples like below
  1. middleware
  2. security
  3. how to add multiple microservices under one api gateway etc..
tomerdomshlak
@tomerdomshlak
Hi, I need some help please :)
All of the sudden, sls deploy to dev is failing and we can't understand why.

The error is:

An error occurred: HttpApiStage - Cannot enable logging. Policy document length breaking Cloudwatch Logs Constraints, either < 1 or > 5120 (Service: AmazonApiGatewayV2; Status Code: 400; Error Code: BadRequestException; Request ID: b47af8e7-47d7-4921-baf8-87de0f8ba253; Proxy: null).

Does anyone has any idea???
Thanks in advance!!!
Gareth McCumskey
@garethmcc
@tomerdomshlak Do you make use of the nested stacks plugins of some kind?
The issue is around the fact that each deployed CloudFormation stack has to generate a IAM policy documents for various reasons. There is a limit as to how large any of these policy documents can be. If you werent using a nested stack plugin, usually you would have gotten an error about attempting to deploy more resources than allowed for a specific CloudFormation stack but using a nested stack plugin bypasses that so now your stack gets large enough to reach the limit of character size for an IAM policy
tomerdomshlak
@tomerdomshlak
Hi @garethmcc . I'll start by saying big thank you for your quick response.
I'll consult with my team and send a response back.
Hannah Scovill
@hnsvill
Hi All - I've noticed when I run a serverless <something> command, it always seems to want to resolve secrets before executing the task I tell serverless to run, even if it's just using a local plugin that has no reason to use the environment variables I have stored with my cloud provider.
What exactly happens when you use a serverless <something> command, anyway? I'd like to disable resolving every bit of the config if I'm just trying to do something simple & local. Then I can save config validation for a separate command I can wrap up into other scripts/pipeline steps.
abuzarhamza
@abuzarhamza
Hi All ,
need a small info . Here is my serverless file .... most event post is not working
serverless has any issue
  user-xxx:
      events:
        - http:
            path: xxx
            method: post
            cors: true
            private: true
        - http:
            path: xxx/{sub_id}
            method: get
            cors: true
            private: true
        - http:
            path: xxx/{sub_id}
            method: post
            cors: true
            private: true
abuzarhamza
@abuzarhamza
i am running the serverless-offline with node 12...
Cody Jenkins
@iknowcss
@tomerdomshlak did you ever find out what was causing your issue? I'm getting the same error and I do not use a nested stack plugin as @garethmcc mentioned. Maybe I have too many resources somehow?
Cody Jenkins
@iknowcss
My problem is solved by disabling HTTP API logs, but I'm not sure why:
#  logs:
#    httpApi: true
Bastien Picharles
@Kleinast
Bonjour a tous,
Je travail actuellement sur un projet lamda avec serverless, qui possède pas mal de event scheduled (cron) et il semble que serverless créer/rajoute une ligne de policy pour chaque event.
Malheuresement, on tombe maintenant sur cette erreur: "The final policy size is bigger than the limit"
N'étant pas très calé en serverless, je voudrai savoir si il y a un moyen de gérer manuellement ou de pouvoir dire a serverless de faire des règle de policy plus global avec des * plutot qu'il me génère une nouvelle règle de policy pour chaque event ?
merci d'avance pour votre aide
hainakus
@hainakus
Hi good afternoon
events with rabbitmq on aws mq setup. can anyone give a clue how to setup it on the yaml?