Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cdk-ecrpublic-gc

Package Overview
Dependencies
Maintainers
1
Versions
175
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cdk-ecrpublic-gc

Garbage collector for Amazon ECR public

  • 0.1.175
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
Maintainers
1
Weekly downloads
 
Created
Source

NPM version PyPI version Release

cdk-ecrpublic-gc

CDK construct library that helps you build a garbage collector to delete all untagged images in Amazon ECR public with AWS CDK.

Why

Amazon ECR public does not have lifecycle policy to clean up all untagged images at this moment(see this issue). cdk-ecrpublic-gc allows you to deploy a AWS Step Functions state machine with dynamic parallelism to invoke an arbitrary of Lambda functions to remove untagged images to release the storage.

Schedule

By default, the state machine will be triggered every 4 hours and can be configured in the schedule property in the TidyUp construct.

Sample

import * as cdk from '@aws-cdk/core';
import { TidyUp } from 'cdk-ecrpublic-gc';

const app = new cdk.App();

const stack = new cdk.Stack(app, 'ecr-public-gc');

new TidyUp(stack, 'TidyUp', {
  repository: [
    'vscode',
    'gitpod-workspace',
    'github-codespace',
  ],
  schedule: events.Schedule.cron({ hour: '*/4', minute: '0' }),
});

In Action

Step Function state machine with dynamic tasks in parallel

Keywords

FAQs

Package last updated on 05 Dec 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc