Skip to content

Instantly share code, notes, and snippets.

View l13t's full-sized avatar
🦇
Working from home

Dmytro Prokhorenkov l13t

🦇
Working from home
View GitHub Profile
@l13t
l13t / monzo-alertmanager-config.yaml
Created August 28, 2019 15:55 — forked from milesbxf/monzo-alertmanager-config.yaml
Monzo's Alertmanager Slack templates
###################################################
##
## Alertmanager YAML configuration for routing.
##
## Will route alerts with a code_owner label to the slack-code-owners receiver
## configured above, but will continue processing them to send to both a
## central Slack channel (slack-monitoring) and PagerDuty receivers
## (pd-warning and pd-critical)
##
{
"__inputs": [
{
"name": "DS_ICINGA2-IDO",
"label": "icinga2-ido",
"description": "",
"type": "datasource",
"pluginId": "mysql",
"pluginName": "MySQL"
}
repos:
#######
# ALL #
#######
- repo: git://github.com/pre-commit/pre-commit-hooks
rev: v2.2.3
hooks:
# Git style
- id: check-added-large-files
@l13t
l13t / remove_deletemarkers.py
Created March 5, 2025 09:49
remove_deletemarkers.py
import boto3
def delete_all_versions(bucket_name):
s3 = boto3.client('s3')
while True:
# List object versions (limited to 1000 per request)
response = s3.list_object_versions(Bucket=bucket_name)
objects_to_delete = []