Skip to content

Latest commit

 

History

History
83 lines (64 loc) · 1.87 KB

README.md

File metadata and controls

83 lines (64 loc) · 1.87 KB

Serverless Cleaner

Clean tools for serverless resources.

Support providers

Usage

Install dependencies

$ npm install

Config

Copy config.example.js to config.js, and config it for yourself.

For example, below is a config for provider Tencent:

module.exports = {
  tencent: {
    // resource region, if not config, you can input when running
    region: 'ap-guangzhou',
    // credentials
    credentials: {
      SecretId: '',
      SecretKey: '',
    },
    apigwOptions: {
      // serviceIds to exclude
      // before you run the clean script, please add your importance service ids here
      // so it will not be cleaned
      exclude: [],

      // serviceIds to include, priority higher than exclude
      // if include set, exclude will be ignored
      include: [],
    },
    scfOptions: {
      // function name to exclude
      // before you run the clean script, please add your importance function names here
      // so it will not be cleaned
      exclude: [],

      // function name to include, priority higher than exclude
      // if include set, exclude will be ignored
      include: [],
    },
    layerOptions: {
      // layer name to exclude
      // before you run the clean script, please add your importance function names here
      // so it will not be cleaned
      exclude: [],

      // layer name to include, priority higher than exclude
      // if include set, exclude will be ignored
      include: [],
    },
  },
};

Start

$ npm run clean

License

Copyright (c) 2020 Serverless Plus