I hereby claim:
- I am laurentr on github.
- I am laurentr (https://keybase.io/laurentr) on keybase.
- I have a public key ASDPfH4-B29Eey16Kxn_lBVTnrxd2PYuMXb-o42lF5CPHAo
To claim this, I am signing this object:
aws ec2 describe-instances | jq -r --arg match "${1}" '.Reservations[]|select(.Instances[]|select((.Tags[]|select(.Key=="Name")|.Value)|match($match)))|select(.Instances[]|select(.State|select(.Name=="running")))|.Instances[].PrivateIpAddress' |
for svc in $(synoservicecfg --list|egrep -iv perl\|ssh) | |
do | |
synoservice --stop "${svc}" | |
done |
{ | |
"Rules": [ | |
{ | |
"Expiration": { | |
"Days": 1 | |
}, | |
"ID": "expire current versions of objects and permanently delete previous versions of objects", | |
"Filter": { | |
"Prefix": "" | |
}, |
I hereby claim:
To claim this, I am signing this object:
# OSX | |
[[ "$(( $(date +"%s") - $(stat -f "%m" ~/.aws/mfa_credentials) ))" -lt "43200" ]] && eval $(aws-mfa) | |
# Linux | |
[[ "$(( $(date +"%s") - $(stat -c "%Y" ~/.aws/mfa_credentials) ))" -lt "43200" ]] && eval $(aws-mfa) |
# if you produce AMIs with naming such as $prefix-$timestamp | |
aws ec2 describe-images --owners self --filters Name=name,Values=PREFIX* --query 'Images[?State==`available`]' | jq -r '.=sort_by(.CreationDate)|.[-1].ImageId' |