Closed Jaffa closed 4 years ago
Alternatively, it might be related to https://github.com/sbstjn/serverless-stack-output/issues/18 ?
Yep, the above is an issue of:
serverless.yml
serverless-stack-output
that uses a promise (e.g. @lucas-carneiro/serverless-stack-output
)
I'm attempting to have a single source project containing both React app and serverless spec, and have
sls deploy
:serverless-stack-output
to update React app with details from CloudFormationnpm build
serverless-s3-sync
to copy the Reactbuild/
directory up to S3.Currently both
serverless-stack-output
andserverless-s3-sync
run offafter:deploy:deploy
asynchronously. I'm not sure there's a way of defining the ordering or dependency between them without writing my own plugin, but it might be sufficient to move S3 sync later (and stack output earlier).I think this could be achieved by changing
after:deploy:deploy
tobefore:deploy:finalize
in index.js.(Alternatively is there a way of defining the {{nos3sync}} for S3 deploy, and I can have the stack-output-handler maybe invoke S3 sync directly?)