I hereby claim:
- I am rblaine95 on github.
- I am cpt_pi (https://keybase.io/cpt_pi) on keybase.
- I have a public key ASBWjpbqjxosW7rfmt0Cc7ySfEICzFiHzXGPSp7wL0W0IQo
To claim this, I am signing this object:
BUCKET="this-is-not-proprietary" | |
JOBS=8 | |
aws s3api list-objects --bucket "$BUCKET" --query \ | |
"Contents[?LastModified<=\`$(date -v-150d '+%Y-%m-%d')\`][].{object: Key}" \ | |
| jq -r '.[].object' \ | |
| parallel -j$JOBS --colsep {} aws s3 rm s3://$BUCKET/{} |
#!/usr/bin/env python3 | |
import itertools | |
from random import shuffle | |
def is_sorted(l): | |
for i in range(len(l)-1): | |
if l[i] > l[i+1]: | |
return False | |
return True |
#!/usr/bin/env python3 | |
from random import shuffle | |
def bogosort(l): | |
while not is_sorted(l): | |
shuffle(l) | |
return l | |
def is_sorted(l): | |
for i in range(len(l)-1): |
I hereby claim:
To claim this, I am signing this object:
import csv | |
import os | |
import string | |
import random | |
import subprocess | |
import sys | |
def main(arg): | |
try: | |
PWD_SIZE = 20 | |
#opens CSV file of desired new users |
#!/bin/sh | |
curl -s https://archlinux.org/mirrorlist/\?country\=$(curl -s https://ifconfig.co/country-iso)\&protocol\=http\&protocol\=https\&ip_version\=4 | sed 's/\#S/S/g' |
#!/bin/bash | |
# Example for the Docker Hub V2 API | |
# Returns all imagas and tags associated with a Docker Hub user account. | |
# Requires 'jq': https://stedolan.github.io/jq/ | |
# set username and password | |
UNAME="" | |
UPASS="" | |
REGISTRY_URL="localhost:5000" |
#!/bin/bash | |
$old=old.registry.net:5000 | |
$new=new.registry.net:5000 | |
$repo="" | |
# Batch pull, tag, push, delete | |
batch() { | |
for x in `wget -q http://$old/v2/_catalog -O - | sed -e 's/[][]//g' -e 's/\,/\n/g' -e 's/\"//g' -e 's/\}//g' | grep $repo | tr '\n' ' '`; do docker pull $old/$x -a; done | |
docker images | grep $old | awk -F' ' '{ print $1":"$2 }' | awk -F '/' '{ print "docker tag "$1"/"$2"/"$3" $new/"$2"/"$3 }' | xargs -L 1 xargs | |
docker images | grep $new | awk -F' ' '{ print $1":"$2 }' | awk -F '/' '{ print "docker push "$1"/"$2"/"$3 }' | xargs -L 1 xargs |