Skip to content

Instantly share code, notes, and snippets.

@jgleonard
jgleonard / wrapper.sh
Last active January 4, 2022 21:24
Wrapper script to ensure output during long-running command
#!/bin/bash
while true; do /bin/echo -n .; sleep 30; done &
eval $*
STATUS=$?
kill $!
exit $STATUS
@jgleonard
jgleonard / lets-encrypt.sh
Created February 22, 2019 15:09
Simple script to deploy cert-manager in Kubernetes using Let's Encrypt
#!/bin/bash
# Email for Let's Encrypt account
EMAIL="[email protected]"
# Install the CustomResourceDefinition resources separately
kubectl apply -f https://raw.githubusercontent.com/jetstack/cert-manager/release-0.6/deploy/manifests/00-crds.yaml
# Create the namespace for cert-manager
kubectl create namespace cert-manager
@jgleonard
jgleonard / rosa-client-dockerfile
Created August 2, 2021 19:52
Dockerfile for Centos image with all utils needed for ROSA, AWS, OCP
FROM centos:8
# Grab dependencies
RUN yum -y update && yum -y install python3-pip golang git
# Install AWS CLI
RUN pip3 install awscli
# Install ROSA CLI
RUN curl https://mirror.openshift.com/pub/openshift-v4/x86_64/clients/rosa/latest/rosa-linux.tar.gz | tar -xzC /usr/local/bin rosa && /usr/local/bin/rosa completion > /etc/bash_completion.d/rosa
@jgleonard
jgleonard / workflow.yml
Last active January 21, 2022 20:27
Actions workflow that bypasses Actions Checks and approves itself in PRs
name: CI
# This workflow will purposely fail a check, then change that status to success.
# It will then approve and merge itself when a PR has been created.
# This is certainly not something you should usually do and I take no responsibility for how it's used.
# This is for informational purposes only.
on:
# Triggers the workflow on pull request events but only for the main branch
pull_request: