pleco

command module
v0.7.22 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 16, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

README

Pleco

Push DockerHub Artifact HUB

Automatically remove cloud and kubernetes resources based on a time to leave tag, ttl.

Protect resources from deletion with a protection tag, do_no_delete.

NOTE: this project is used in Qovery's production environment


Supported resources

  • AWS
    • Document db databases
    • Elasticache databases
    • RDS databases
    • EBS volumes
    • ELB load balancers
    • EC2 Key pairs
    • ECR repositories
    • EKS clusters
    • IAM groups
    • IAM users
    • IAM policies
    • IAM roles
    • Cloudwatch logs
    • KMS keys
    • VPC vpcs
    • VPC internet gateways
    • VPC route tables
    • VPC subnets
    • VPC security groups
    • S3 buckets
  • DIGITAL OCEAN
  • AZURE
  • GCP

Installation

You can find a helm chart here, a docker image here and all binaries are on github.


Requirements

In order to make pleco check and clean expired aws resources you need to set the following environment variables:

$ export AWS_ACCESS_KEY_ID=<access_key>
$ export AWS_SECRET_ACCESS_KEY=<secret_key>

Basic command

A pleco command has the following structure:

pleco start [options]
General options
Debug Level

You can set the debug level with:

--level <log level>

Default is "info"

Check's interval

You can set the interval between two pleco's check with:

--check-interval, -i <time in seconds>

Default is "120"

Dry Run

If you disable dry run, pleco will delete expired resources. If not it will only tells you how many resources are expired.

You can disable dry-run with:

--disable-dry-run, -y

Default is "false"

AWS options
Region selector

When pleco's look for expired resources, it will do it by aws region.

You can set region(s) with:

--aws-regions, -a <region(s)>

For exemple:

-a eu-west-3,us-east-2

####Resources Selector When pleco is running you have to specify which resources expiration will be checked.

Here are some the resources you can check:

--enable-eks, -e # Enable EKS watch
--enable-iam, -u # Enable IAM watch (groups, policies, roles, users)
Example
pleco start --level debug -i 240 -a eu-west-3 -e -r -m -c -l -b -p -s -w -n -u -z -o -y

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
providers
aws
k8s

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL