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

No alias is created when the serverless-plugin-split-stacks plugin is also used #188

Open
ziadloo opened this issue Apr 18, 2020 · 2 comments

Comments

@ziadloo
Copy link

ziadloo commented Apr 18, 2020

I've been using the serverless-aws-alias plugin for some time now. It had its ups and downs but now I faced a problem that I cannot overcome.

My serverless project grew too big to be deployed into one CloudFormation stack (I faced the 200 resources limitation of CloudFormation). After some research, I found the serverless-plugin-split-stacks plugin. This plugin will split your stacks into nested ones. And it works on its own. But as my project uses the serverless-aws-alias plugin plugin, while I still can deploy the project without any errors reported, but the lambda functions created have no aliases created for them.

Here's a simple test case:

service: serverless-test

provider:
  name: aws
  runtime: nodejs12.x
  endpointType:                                REGIONAL

plugins:
- serverless-plugin-split-stacks
- serverless-aws-alias

custom:
  splitStacks:
    nestedStackCount: 20
    perFunction: false
    perType: false
    perGroupFunction: true

functions:
  create:
    handler: code.get
    events:
      - http:
          path: /
          integration:                           lambda
          method: get
          cors: true

If you deploy this project like this:

sls deploy --region us-east-1 --stage dev --alais dev

You'll end up with a lambda function without any aliases.

Here are my versions:

$ sls -v
Framework Core: 1.61.2
Plugin: 3.6.6
SDK: 2.3.0
Components Core: 1.1.2
Components CLI: 1.4.0

$ cat ./package.json 
{
  "name": "serverless-test",
  "version": "1.0.0",
  "description": "",
  "main": "code.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "devDependencies": {
    "serverless-aws-alias": "^1.8.0",
    "serverless-plugin-split-stacks": "^1.9.3"
  }
}
@vsaravind007
Copy link

+1 Having the same issue

@ydan287
Copy link

ydan287 commented Nov 5, 2020

+1 having the same issue

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

3 participants