Coder Social home page Coder Social logo

manwaring / serverless-prune-versions Goto Github PK

View Code? Open in Web Editor NEW
3.0 3.0 0.0 1.06 MB

A Serverless Framework plugin which automates the removal of old and unused Lambda and Lambda Layer versions to help keep you under the 75GB AWS Lambda storage limit

License: MIT License

JavaScript 0.91% TypeScript 98.81% Shell 0.28%
lambda lambda-layer serverless-framework serverless-plugin

serverless-prune-versions's Introduction

Hello!

I'm a serverless architect and developer, using managed services first and FaaS when necessary to experiment and solve business problems as quickly and effectively as I can with the least amount of operational overhead possible. I prefer TypeScript > JavaScript > Java. IaC and automate all the things!

Some of my favorite tools include AWS, CircleCI, and the Serverless Framework. I recently started working with Jeremy Daly's DynamoDB Toolbox library and I'm loving it - it's the best library I've found to simplify working with single-table designs.

I'm really proud of the applications and libraries that I've pinned below. I built each one in response to challenges that were (as far as I could tell) unsolved at the time, and after reusing them on a handful of projects I decided to publish them in the hopes that others could benefit as well. I aim to be as responsive as possible to issues and suggestions and I'm always looking for collaborators to work with - you can find me on Twitter or LinkedIn if you want to connect.

Happy coding!

serverless-prune-versions's People

Contributors

dependabot-preview[bot] avatar dependabot[bot] avatar manwaring avatar phillipmanwaring avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

serverless-prune-versions's Issues

No predefined types for the introduces options.

CLI options definitions were upgraded with "type" property (which could be one of "string", "boolean", "multiple"). Below listed plugins do not predefine type for introduced options:
   - PrunePlugin for "number", "stage", "region", "function", "layer", "includeLayers", "dryRun"
  
  Please report this issue in plugin issue tracker.

Requiring a name field for the layer configuration

When trying to use this to prune layers, it may be worth mentioning that having the name field is required in the layer configuration for this to work even though its optional on AWS' end, as shown here: https://www.serverless.com/framework/docs/providers/aws/guide/layers#configuration

In the serverless.yaml, these 2 things are required for the layer configuration for this plugin to work:

layers:
  myLayer:
    path: /path/to/layer
    name: myLayer <-- This MUST be populated for this plugin to work

If the layer does not have the name field, then this plugin will fail and you'll get an error like Missing required key 'LayerName' in params. It would probably be best to mention this in the README or something for future reference so users know they need to include the optional name parameter for this plugin to work.

Here is my current custom plugin config, if youre curious:

custom:
  prune:
    automatic: true
    includeLayers: true
    number: 3
    layer: myLayer

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.