serverless-localstack icon indicating copy to clipboard operation
serverless-localstack copied to clipboard

Option to select services

Open techdragon opened this issue 5 years ago • 3 comments

It would be useful if there was an option to only specify some services, if would be easier to use this plugin if it didnt try to enable (and use) localstack for everything. For instance I looked at using this plugin to do some development against SQS, but decided to write a script to launch the docker file manually because of all the issues regarding the lambda environment not working.

┆Issue is synchronized with this Jira Task by Unito

techdragon avatar Sep 10 '20 16:09 techdragon

Thanks for reporting @techdragon . Can you please elaborate a bit more on the specific use case you had in mind.

We can certainly make the plugin configurable in such a way that the plugin itself would only connect to the local APIs for certain services. However, ultimately the Serverless framework under the covers creates a CloudFormation template, which is then sent to the LocalStack CloudFormation API to deploy all the resources.

Just to understand your use case a bit better: Assuming you have, say, an SQS queue and a Lambda function in your serverless.yml - are you saying that you'd like to deploy the SQS queue against LocalStack, but the Lambda function against real AWS..? In that case, we would have to make a change to LocalStack itself (and it might not be a trivial one) - but I just want to make sure I understand correctly.

Can you please share some details and a small example of what you're trying to achieve? Thanks!

whummer avatar Nov 01 '20 14:11 whummer

➤ Waldemar Hummer commented:

Thanks for reporting techdragon . Can you please elaborate a bit more on the specific use case you had in mind.

We can certainly make the plugin configurable in such a way that the plugin itself would only connect to the local APIs for certain services. However, ultimately the Serverless framework under the covers creates a CloudFormation template, which is then sent to the LocalStack CloudFormation API to deploy all the resources.

Just to understand your use case a bit better: Assuming you have, say, an SQS queue and a Lambda function in your serverless.yml

  • are you saying that you'd like to deploy the SQS queue against LocalStack, but the Lambda function against real AWS..? In that case, we would have to make a change to LocalStack itself (and it might not be a trivial one) - but I just want to make sure I understand correctly.

Can you please share some details and a small example of what you're trying to achieve? Thanks!

sync-by-unito[bot] avatar Nov 13 '20 16:11 sync-by-unito[bot]

The issue that prompted me to file this, was that I was using the Serverless' built in Lambda runner for specific features it supported, also wanting to use LocalStack for SQS, but not wanting to use LocalStack's Lambda runner... because it didn't support the feature I was already using that Serverless' Lamda runner does support.

techdragon avatar Mar 02 '21 06:03 techdragon