Skip to content

Instantly share code, notes, and snippets.

@charz
charz / swift-expired-status
Last active October 5, 2020 08:43 — forked from clayg/swift-expired-status
check on the expirer queue
#!/usr/bin/env python
from collections import defaultdict
import sys
import time
import socket
from argparse import ArgumentParser
from swift.common.internal_client import InternalClient
from swift.common.utils import Timestamp
from swift.common.wsgi import ConfigString
@charz
charz / internal_logs.py
Created February 14, 2018 02:51 — forked from clayg/internal_logs.py
dig around in internal logs account
#!/usr/bin/env python
import argparse
import logging
import sys
import thread
import threading
from Queue import Queue
from datetime import datetime, timedelta
@charz
charz / s3etag.sh
Created August 30, 2016 04:25 — forked from emersonf/s3etag.sh
A Bash script to compute ETag values for S3 multipart uploads on OS X.
#!/bin/bash
if [ $# -ne 2 ]; then
echo "Usage: $0 file partSizeInMb";
exit 0;
fi
file=$1
if [ ! -f "$file" ]; then
@charz
charz / custom.js
Created September 26, 2013 08:59 — forked from drewjoh/custom.js
$(document).ready(function() {
// Support for AJAX loaded modal window.
// Focuses on first input textbox after it loads the window.
$('[data-toggle="modal"]').click(function(e) {
e.preventDefault();
var url = $(this).attr('href');
if (url.indexOf('#') == 0) {
$(url).modal('open');
} else {