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 | |
SHA256_HASH="5bb4faffc8b35e2702b2ffa78e982b979d7b66db29bd55b0c58de8fa745df661" | |
for i in {1..1000} | |
do | |
echo "Looking into page: $i" | |
curl "https://registry.hub.docker.com/v2/repositories/apache/superset/tags/?page=$i" \ | |
| jq '.results[] | select(.["images"][]["digest"] == "sha256:'${SHA256_HASH}'")' |
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 | |
AWS_ENVIRONMENT="production" | |
SSH_PUBLIC_KEY="ssh-ed25519 XXXYYYZZZexampleXXXYYYZZZ/XYZXYZ [email protected]" | |
# Copy the key to a temporary location | |
touch /tmp/id_ed25519.pub | |
echo "${SSH_PUBLIC_KEY}" > /tmp/id_ed25519.pub | |
# See all machines in all regions |
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 | |
## VARIABLES | |
BUCKET_NAME="YOUR-BUCKET-TO-PROCESS" | |
BUCKET_PREFIX="THE-PREFIX-TO-START-PROCESSING/" | |
NEXT_FILE_TO_PROCESS="" | |
BASE_LIST_COMMAND="aws s3api list-objects-v2 --bucket ${BUCKET_NAME} --prefix ${BUCKET_PREFIX} --output text --query 'Contents[].Key' --max-items 100 --page-size 100" |
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 | |
LOCAL_EXIT_CODE=0 | |
# Get a list of projects from Gcloud | |
PROJECTS=($(gcloud projects list --format="value(projectId)")) | |
# Create a directory to split clusters kubeconfig files later | |
mkdir -p "${HOME}/.kube/clusters" |
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 | |
LOCAL_EXIT_CODE=0 | |
RELEASE_NAME="istiod" | |
RELEASE_NAMESPACE="istio-system" | |
HELM_CHART_PATH="./istio/istiod" | |
HELM_EXTRA_VALUES_PATH="./istio/common/istio.yaml" | |
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 | |
function prompt_for_multiselect { | |
# little helpers for terminal print control and key input | |
GREEN='\033[00;32m' | |
YELLOW='\033[00;33m' | |
RESTORE='\033[0m' | |
ESC=$( printf "\033") | |
cursor_blink_on() { printf "$ESC[?25h"; } |