Skip to main content

Intro




sls-mentor

We are open to contributions, check our good first issues!

npm packagenpm downloads


Just because you don't see something, doesn't mean it doesn't exist

Anonymous on Tumblr - 2012


sls-mentor is a tool that analyzes the configuration of your AWS resources against best practice rules.
sls-mentor solves problems before they occur, and optimizes your app’s performances and costs.



One minute quick start 🚀


npx sls-mentor



Install sls-mentor on your project and customize your experience 🔎


yarn add -D sls-mentor

Select the cloudformation stacks you want to check using -c option

yarn sls-mentor -c YOUR_AWS_STACK_NAME_1 YOUR_AWS_STACK_NAME_2

Filter the checked resources by tags using the -t option

yarn sls-mentor -t Key=TAG_KEY,Value=TAG_VALUE

Specify an AWS profile or an AWS region using -p and -r options

yarn sls-mentor -p YOUR_AWS_PROFILE -c YOUR_AWS_STACK_NAME -r YOUR_AWS_REGION

📚 More information about local runs of sls-mentor



Run sls-mentor as a periodic check on your CI 📟


The command you want to run in your pipeline is:

yarn sls-mentor -p YOUR_AWS_PROFILE -c YOUR_AWS_STACK_NAME -r YOUR_AWS_REGION -l YOUR_DESIRED_LEVEL

Github actions, Circle CI, Gitlab CI configuration snippets coming soon 🚀


⚠️ To make sure it properly works when executed by a pipeline runner:

  • Ensure that the CI/CD runner has an AWS profile configured, with ReadOnlyAccess privileges
  • If the region is not configured for that profile, make sure to specify it using the -r flag in the command
  • 📚 More information about CI runs of sls-mentor



    Rules featured by sls-mentor 📏


    AWS Lambda:AWS S3:AWS SQS:AWS Cognito:AWS CloudWatch:AWS EventBridge:AWS CloudFront:AWS RDS:AWS Backup:AWS Api Gateway V2:

    Check out our articles, to find out more:



    About sls-mentor 📰


    sls-mentor is a Theodo Group project made for AWS Serverless developers by AWS Serverless developers. Original idea appeared at Aleios. sls-mentor was migrated to Typescript and enriched by Theodo.



    Contributors ❤️




    Your contributions are very welcome, feel free to add new rules to sls-mentor !