This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
[[ "$1" == "yes" ]] || { echo "Specify \"yes\" to nuke Helix Native"; exit 0; } | |
echo | |
echo "NUKING HELIX NATIVE!" | |
echo | |
FOLDERS=( | |
"${HOME}/Library/Application Support/Line 6" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# REGISTER OR DEREGISTER INSTANCES WITH/FROM ELB CLASSIC | |
## SANDBOX/PLAY ACCOUNT | |
ELBNAME=23feb22 | |
INSTANCES=( | |
i-0673baad826269229 # Name: dummy1 | |
i-0a72c8136b4ee5042 # Name: dummy2 | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# see: https://stackoverflow.com/questions/16860877/remove-an-element-from-a-bash-array | |
array=(pluto pippo bob john 1 56) | |
echo "array: ${array[*]}" | |
echo | |
delete=(pippo 56) | |
echo "delete: ${delete[*]}" | |
for target in "${delete[@]}"; do | |
for i in "${!array[@]}"; do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
array=(pluto pippo bob) | |
echo "array: ${array[*]}" | |
echo | |
addlist=(mike john) | |
echo "add list: ${addlist[*]}" | |
array+=(${addlist[*]}) | |
echo "${array[@]}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Export AWS Well-Architected Tool Workload ARNs to CSV | |
usage(){ | |
echo "EXPORT WELL-ARCHITECTED TOOL WORKLOAD ARNs TO CSV | |
ARGUMENTS: | |
-d | --days \${number of days} - number of days to include (since last update). Default 3650 | |
-u | --upload | --arns - output APN portal upload-friendly CSV of ARNs only | |
-h | --help - this output |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# shellcheck disable=2086,2162,2005,2046,1091 | |
# GET AWS SESSION TOKEN WITH MFA | |
# allowing CLI access to commands without switching to an IAM Role, e.g. for accessing the Well-Architected Tool | |
source colours > /dev/null 2>&1 # import colours script if it exists in the PATH | |
usage(){ | |
echo " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# shellcheck disable=SC2034 | |
# API DOCUMENTATION: https://docs.datadoghq.com/api/latest/aws-integration/ | |
# ============================================================ | |
# TO BE REMOVED AND PROVIDED VIA EXPORTS | |
DD_API_KEY="DATADOG_API_KEY" | |
DD_APPLICATION_KEY="DATADOG_APPLICATION_KEY" | |
ACCOUNTID="AWS_ACCOUNT_ID" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# BASE | |
tap "homebrew/bundle" | |
tap "homebrew/cask" | |
tap "homebrew/core" | |
# BASE Apps | |
cask "joplin" | |
cask "bettertouchtool" | |
cask "visual-studio-code" | |
cask "bitwarden" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Get supported EC2 instance types in the current account and region. If you | |
# only need to check for specific types, then specify them in types.txt in | |
# the script directory, otherwise it will process all available instance types | |
# in the region. Tested on MacOS. | |
# Prereqs: awscli, jq | |
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" | |
TMPTYPES=/tmp/types |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Generate presigned URLs for every object in a given bucket | |
# Outputs markdown. Preview in IDE and copy to email. | |
# Prereqs: awscli, jq | |
EXPIRY=604800 # in SECONDS | |
BUCKET=$1 | |
OUTFILE=$BUCKET-signed-urls.md |