question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

sls create: Install missing plugins automatically

See original GitHub issue

Use case description

The nice thing about Serverless Framework is the dev experience. sls create / sls deploy.

But if the author has used a plugin, and you try to deploy it, you get something like this:

Serverless plugin "serverless-step-functions" not found. Make sure it's installed and listed in the "plugins" section of your serverless config file.

Then you have to Google to find out you need to run something like:

sls plugin install -n serverless-step-functions

Proposed solution

If the plugin isn’t there, run the command automatically for the user to install the missing plugins.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:4
  • Comments:12 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
medikoocommented, Jun 7, 2021

Closing as it can be considered as addressed with https://github.com/serverless/serverless/pull/9483

For project setup we’re moving from sls create to sls, and when setting up the project with sls dependencies are installed for copied template (released with v2.42.0)

1reaction
medikoocommented, Jul 16, 2020

@a-h thanks for clarification, that significantly changes the scope, as sls init is a command we’ve implemented recently which follows up with npm install (if package.json is part of a template).

I take then, this is a request to install missing plugins on sls create (so issue npm install if package.json is there) Note that in Serverless ecosystem it is assumed that plugins are published to npm, and it’s the only package manager that internally is supported by the CLI

Read more comments on GitHub >

github_iconTop Results From Across the Web

Plugins - Serverless Framework
Plugins are installed per service. They are not applied globally. To install a plugin, run the following command in a service directory:
Read more >
Serverless - Plugins - Tutorialspoint
Then, following the documentation, run the following command to install the plugin − sls plugin install -n serverless-python-requirements.
Read more >
serverless-offline - npm
Serverless Offline. This Serverless plugin emulates AWS λ and API Gateway on your local machine to speed up your development cycles.
Read more >
Serverless Framework | Epsagon Documentation
The plugin will be activated automatically during sls deploy , sls package , and sls invoke local events automatically. To cleanup any Epsagon-related...
Read more >
Datadog Serverless Framework Plugin
The plugin automatically enables instrumentation for applications to collect metrics, traces, and logs by: Installing the Datadog Lambda library to your ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found