cancel
Showing results for 
Search instead for 
Did you mean: 

I am trying to deploy dsh-predmnt to my personal aws account but serverless is throwing a lot of errors. I followed the PDF document "How to deploy DSH-PREDMNT in proprietary AWS account" . Is there a more detailed instruction on deploying to AWS??

VChak.1
Associate II

PS C:\pm\predictive_maintenance_fe\serverless>node --version

v14.16.1

PS C:\pm\predictive_maintenance_fe\serverless>npm --version

7.11.1

PS C:\pm\predictive_maintenance_fe\serverless>npm install

   up to date, audited 190 packages in 2s

   6 packages are looking for funding

   run `npm fund` for details

   found 0 vulnerabilities

PS C:\pm\predictive_maintenance_fe\serverless>

PS C:\pm\predictive_maintenance_fe\serverless> serverless deploy --verbose

Serverless: Deprecation warning: Serverless Framework was enhanced with a new variables resolver which doesn't recognize "provider.variableSyntax" setting.Starting with a new major it will be the only resolver that's used.. Drop setting from a configuration to adapt to it

   More Info: https://www.serverless.com/framework/docs/deprecations/#NEW_VARIABLES_RESOLVER

[dataLakeZipBuilder] lambda configured with buckets: pmsensors-weeklylake and pmsensors-ziplake

[zipFileRemover] lambda configured with bucket: pmsensors-ziplake

Serverless: Deprecation warning: CLI options definitions were upgraded with "type" property (which could be one of "string", "boolean", "multiple"). Below listed plugins do not predefine type for introduced options:

    - AdditionalStacksPlugin for "skip-additionalstacks", "stack"

    - Remover for "verbose"

    - Assets for "verbose", "bucket"

   Please report this issue in plugin issue tracker.

   Starting with next major release, this will be communicated with a thrown error.

   More Info: https://www.serverless.com/framework/docs/deprecations/#CLI_OPTIONS_SCHEMA

Serverless: Deprecation warning: Unresolved variable references will be communicated with a thrown error, starting from next major

   More Info: https://www.serverless.com/framework/docs/deprecations/#VARIABLES_ERROR_ON_UNRESOLVED

 Serverless Warning --------------------------------------

 A valid file to satisfy the declaration 'file(./output.json):CDNDistributionId' could not be found.

Serverless: Configuration warning at 'functions.customResourceLambda': unrecognized property 'DependsOn'

Serverless:

Serverless: Learn more about configuration validation here: http://slss.io/configuration-validation

Serverless:

Serverless: Deprecation warning: Starting with next major, Serverless will throw on configuration errors by default. Adapt to this behavior now by adding "configValidationMode: error" to service configuration

   More Info: https://www.serverless.com/framework/docs/deprecations/#CONFIG_VALIDATION_MODE_DEFAULT

Serverless: Deprecation warning: Support for "package.include" and "package.exclude" will be removed with next major release. Please use "package.patterns" instead

   More Info: https://www.serverless.com/framework/docs/deprecations/#NEW_PACKAGE_PATTERNS

Serverless: Packaging service...

Serverless: WARNING: Function dataLakeZipBuilder has timeout of 900 seconds, however, it's attached to API Gateway so it's automatically limited to 30 seconds.

Serverless: Deploying additional stacks...

Serverless: Writing template for additional stack eventsQueueNestedStack...

Serverless: Creating additional stack eventsQueueNestedStack...

...

Serverless: Additional stack eventsQueueNestedStack created successfully (CREATE_COMPLETE).

Serverless: Writing template for additional stack zipBuilderNestedStack...

Serverless: Creating additional stack zipBuilderNestedStack...

......

Serverless: Additional stack zipBuilderNestedStack create failed (ROLLBACK_COMPLETE).

 Error ---------------------------------------------------

 Error: Additional stack zipBuilderNestedStack create failed (ROLLBACK_COMPLETE)

  at C:\pm\predictive_maintenance_fe\serverless\node_modules\serverless-plugin-additional-stacks\index.js:480:37

  at processTicksAndRejections (internal/process/task_queues.js:93:5)

  at async PluginManager.invoke (C:\Users\chakradhar\AppData\Roaming\npm\node_modules\serverless\lib\classes\PluginManager.js:552:9)

  at async PluginManager.run (C:\Users\chakradhar\AppData\Roaming\npm\node_modules\serverless\lib\classes\PluginManager.js:598:7)

  at async Serverless.run (C:\Users\chakradhar\AppData\Roaming\npm\node_modules\serverless\lib\Serverless.js:313:5)

  at async C:\Users\chakradhar\AppData\Roaming\npm\node_modules\serverless\scripts\serverless.js:634:9

  For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.

 Get Support --------------------------------------------

  Docs:   docs.serverless.com

  Bugs:   github.com/serverless/serverless/issues

  Issues:  forum.serverless.com

8 REPLIES 8
niccolò
ST Employee

Hi @VChak.1​ ,

the issue could lie in compatibility o versions used for the deploy

Can you try to use serverless --version Framework Core: 1.70.1 Plugin: 3.6.11 SDK: 2.3.0 Components: 2.30.10 and run it again?

hope this helps

Niccolò

I tried your suggestion but still the deploy is failing ...

C:\predictive_maintenance_fe\serverless>serverless --version

Framework Core: 1.70.1

Plugin: 3.8.4

SDK: 2.3.2

Components: 2.34.9

C:\predictive_maintenance_fe\serverless>node --version

v12.22.1

C:\predictive_maintenance_fe\serverless>npm --version

7.11.1

C:\predictive_maintenance_fe\serverless> serverless deploy --verbose

Serverless: Deploying additional stacks...

Serverless: Writing template for additional stack eventsQueueNestedStack...

Serverless: Creating additional stack eventsQueueNestedStack...

Serverless: Additional stack eventsQueueNestedStack created successfully (CREATE_COMPLETE).

Serverless: Creating additional stack zipBuilderNestedStack...

Serverless: WARNING: Inappropriate call of provider.request()

Serverless: [AWS cloudformation 200 0.19s 0 retries] describeStacks({ StackName: 'predictive-maintenance-dev-zipBuilderNestedStack' })

Serverless: Additional stack zipBuilderNestedStack create failed (ROLLBACK_COMPLETE).

 Error --------------------------------------------------

 Error: Additional stack zipBuilderNestedStack create failed (ROLLBACK_COMPLETE)

   at C:\predictive_maintenance_fe\serverless\node_modules\serverless-plugin-additional-stacks\index.js:480:37

 From previous event:

   at processImmediate (internal/timers.js:461:21)

 From previous event:

   at readMore (C:\predictive_maintenance_fe\serverless\node_modules\serverless-plugin-additional-stacks\index.js:462:10)

 Your Environment Information ---------------------------

   Operating System:     win32

   Node Version:       12.22.1

   Framework Version:     1.70.1

   Plugin Version:      3.8.4

   SDK Version:        2.3.2

   Components Version:    2.34.9

C:\predictive_maintenance_fe\serverless>

On the CloudFormation Stack Error Event In AWS Console ...

Logical ID:

predictive-maintenance-dev-zipBuilderNestedStack

ERROR EVENT:

The following resource(s) failed to create: [zipFileRemoverRole, zipBuilderRole, roleForDataLakeWeeklyAggregatorLambda, weeklyAggregationLake, zipTable, weeklyAggregationBucketPolicy, dataLake, zipLake]. Rollback requested by user.

The IAM User used for serverless is an Administrator With Full Access and the Additional stack eventsQueueNestedStack is created successfully.

But create "predictive-maintenance-dev-zipBuilderNestedStack" is FAILING .

Please help.

Hi @VChak.1​ ,

maybe you need to manually delete anything that was created before the error

then you can retry to run serverless and let me know if it works this way

Niccolò

Yes I removed the app using - serverless remove

I uninstalled the Nodejs, NPM and Serverless ..

I deleted the entire predictive_maintenance_fe folder

I deleted the Node .. .serverless in <user folder>

I removed/deleted everything on the AWS account ... buckets and the Additional stack eventsQueueNestedStack... deleted the IAM user.

I created a new IAM user with Admin permissions.

... restarted the Win 10 PC

Reinstalled NodeJS, NPM, Serverless

Unzipped a fresh predictive_maintenance_fe folder.

created the config folder and the config file

In c:\predictive_maintenance_fe \serverless\

npm install

serverless deploy --verbose

I get the same error.

Serverless: Creating additional stack eventsQueueNestedStack...

Serverless: Additional stack eventsQueueNestedStack created successfully (CREATE_COMPLETE).

Serverless: Creating additional stack zipBuilderNestedStack...

Serverless: WARNING: Inappropriate call of provider.request()

Serverless: Additional stack zipBuilderNestedStack create failed (ROLLBACK_COMPLETE).

 Error --------------------------------------------------

 Error: Additional stack zipBuilderNestedStack create failed (ROLLBACK_COMPLETE)

   at C:\predictive_maintenance_fe\serverless\node_modules\serverless-plugin-additional-stacks\index.js:480:37

 From previous event:

   at processImmediate (internal/timers.js:461:21)

 From previous event:

   at readMore (C:\predictive_maintenance_fe\serverless\node_modules\serverless-plugin-additional-stacks\index.js:462:10)

My Environment Information ---------------------------

   Operating System:     win32

   Node Version:       12.22.1

   Framework Version:     1.70.1

   Plugin Version:      3.8.4

   SDK Version:        2.3.2

   Components Version:    2.34.9

Is there anything I need to do on the AWS ?? before deploying the app. I created buckets and IAM user with Admin permission.

Additional stack eventsQueueNestedStack is getting created successfully but getting stuck with predictive-maintenance-dev-zipBuilderNestedStack .

Hi @VChak.1​ ,

before deploying the app you should erase everything manually, and then start from zero

it seems to me that you created the buckets, but it is the deploy that should do it, so it fails when it tries to create them

please, try to restart from square one (everything erased) and start the deploy without creating anything manually

let me know if this solves your problem

Niccolò

Thanks niccolo.ruffini. I tried both ways i.e.,

1. I Let the serverless create all the resources on the AWS including buckets on a fresh AWS Account with IAM user with ADMIN role. The result was error at creating zipBuilderNestedStack role.

2.- I then created four buckets using the same IAM use with ADMIN role and then tried to deploy - the same error popped out.

3.- I created an additional role "IAM Managed Policy" for the CloudFormation service and then tried to deploy the app ... this time it was successful and I could browse through the App with the CloudFront URL without any issue.

What you said finally worked for me - Serverless 1.70.10, NodeJS 12.xx , SDK version 2.3.x. And let the deployment create all the required resources on the AWS. In addition I had to add "IAM Managed Policy" to the CloudFormation Service manually using AWS Console for the serverless to deploy the app successfully.

Thanks a lot for the help and support.

Hi @VChak.1​ ,

you are welcome, I'm happy to hear that the problem is solved.

can I ask you to select the best answer to help other user with similar issues to find the solution?

hope to see you again here on the community

Niccolò

Fgedf.1
Associate

I am also trying to deploy it to my personal aws account amd facing this issue that you mentioned here why the service is looking very ordinary in this task?