Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
TMATE_URL=https://github.com/tmate-io/tmate/releases/download/2.4.0/tmate-2.4.0-static-linux-amd64.tar.xz
VERSION_FILENAME=$(basename -s .tar.xz "${TMATE_URL}")
DEPLOY_DIR=/opt/tmate
sudo mkdir -p /opt/tmate
cd /opt/tmate
sudo curl -RLOJ "${TMATE_URL}"
sudo tar -xJvf "${VERSION_FILENAME}.tar.xz"
sudo ln -sf "${DEPLOY_DIR}/${VERSION_FILENAME}/tmate" "/usr/local/bin/tmate"
###
# Create mirror repo following disconnected instructions
###
# create dir
mkdir -p ~/registry1/{auth,certs,data}
# create cert
openssl req -newkey rsa:4096 -nodes -sha256 -keyout ~/registry1/certs/domain.key -x509 -days 365 -out ~/registry1/certs/domain.crt
@miiraheart
miiraheart / disconnected-operators.md
Created September 6, 2020 14:21 — forked from sjenning/disconnected-operators.md
disconnected-operators
@miiraheart
miiraheart / SSL-certs-OSX.md
Created October 21, 2020 16:34 — forked from croxton/SSL-certs-OSX.md
Generate ssl certificates with Subject Alt Names

Generate ssl certificates with Subject Alt Names on OSX

Open ssl.conf in a text editor.

Edit the domain(s) listed under the [alt_names] section so that they match the local domain name you want to use for your project, e.g.

DNS.1   = my-project.dev

Additional FQDNs can be added if required:

@miiraheart
miiraheart / .gitignore
Created June 9, 2022 13:05 — forked from cvarjao/.gitignore
OpenShift oc command line cheatsheet
images/
layers/
node_modules/
.cache/
manifests/
@miiraheart
miiraheart / README.md
Created April 12, 2023 13:24 — forked from gullitmiranda/README.md
Remote support or pair programing cheet sheet with http://tmate.io
  1. Install http://tmate.io

  2. Configure ~/.tmux.conf

    curl -sSL -o ~/.tmux.conf https://gist.github.com/gullitmiranda/e631f14a66a8ff658eb7/raw/fc3cfb7cd2ef1cc6e5d0de66b1e93b68652de866/tmux.conf
  3. Start tmate server

#!/usr/bin/env bash
NAMESPACE=your_namespace_on_quay
TAG=the_tag
# https://quay.io/organization/your_namespace_on_quay?tab=applications
ACCESS_TOKEN=xxxxx
for repository in $(curl -s -X GET -H "Authorization: Bearer $ACCESS_TOKEN" "https://quay.io/api/v1/repository?namespace=$NAMESPACE" | jq -r '.repositories[].name' | sort); do
curl -s -X DELETE -H "Authorization: Bearer $ACCESS_TOKEN" https://quay.io/api/v1/repository/$NAMESPACE/$repository/tag/$TAG