# Moving lambdas between stacks being deployed by CodeFresh.

**URL:** <https://forum.serverless.com/t/moving-lambdas-between-stacks-being-deployed-by-codefresh/16551>\
**Category:** Serverless Framework\
**Tags:** aws, lambda, api-gateway, cicd\
**Created:** [January 15, 2022, 8:42am UTC](https://forum.serverless.com/t/moving-lambdas-between-stacks-being-deployed-by-codefresh/16551 "2022-01-15T08:42:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![darek-gc](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/darek-gc/32/6444_2.png) [@darek-gc](https://forum.serverless.com/u/darek-gc)\
**Post date:** [January 15, 2022, 8:42am UTC](https://forum.serverless.com/t/moving-lambdas-between-stacks-being-deployed-by-codefresh/16551/1 "2022-01-15T08:42:21Z")

</div>

We have two steps in the deploy stage: “Stack A” and “Stack B”. Currently “Stack A” deploys lambda together with API Gateway “/complete” path.

We need to move the lambda to “Stack B”. So we removed it from serverless.yml “Stack A” and added it to “Stack B”.

To avoid issues related to trying to deploy “/complete” path with “Stack B” before “Stack A” with removed “/complete” path will be deployed, we made deployment of “Stack B” dependent on successful deployment of “Stack A”.  
Unfortunately, this means that we have to expect downtime on path “/complete” between deployment of “Stack A” with removed “/complete” and deployment of “Stack A” with added “/complete”.

Is there any way to do it without downtime on /complete?
