Skip to content

Instantly share code, notes, and snippets.

View darron's full-sized avatar
🎯
Focusing

darron froese darron

🎯
Focusing
View GitHub Profile
# HELP build_info Build and version information
# TYPE build_info gauge
build_info{goversion="go1.21.5-devel-cf",revision="2024-01-17-1028 UTC",type="",version="2024.1.3"} 1
# HELP cloudflared_config_local_config_pushes Number of local configuration pushes to the edge
# TYPE cloudflared_config_local_config_pushes counter
cloudflared_config_local_config_pushes 1
# HELP cloudflared_config_local_config_pushes_errors Number of errors occurred during local configuration pushes
# TYPE cloudflared_config_local_config_pushes_errors counter
cloudflared_config_local_config_pushes_errors 0
# HELP cloudflared_orchestration_config_version Configuration Version
@darron
darron / openpgp.md
Last active January 15, 2024 23:24

openpgp4fpr:9B90C6FA81376CBD269FFF8E84D4A686885DC772

echo -n $SECRET | gcloud kms encrypt --project dapper-ops --location global --keyring sre --key wrapped-secrets \
--plaintext-file - \
--ciphertext-file - \
| base64
@darron
darron / gist:3ab0c517b71b96cd9567098675dbc246
Last active September 8, 2021 23:12
Helm Chart Hosting Options
Helm Chart Hosting
Github Pages:
https://harness.io/blog/devops/helm-chart-repo/
https://faun.pub/how-to-host-helm-chart-repository-on-github-b76c854e1462
Private Github Repo (GITHUB_TOKEN):
https://blog.softwaremill.com/hosting-helm-private-repository-from-github-ff3fa940d0b7
diff --git a/bin/test-compile b/bin/test-compile
index 219a688..0a21748 100755
--- a/bin/test-compile
+++ b/bin/test-compile
@@ -24,5 +24,5 @@ if [ -f "${build}/.golangci.yml" -o -f "${build}/.golangci.toml" -o -f "${build}
step "/.golangci.{yml,toml,json} detected"
tmp="$(mktemp -d)"
mkdir -p "${build}/.heroku/golangci/bin"
- ensureFile "golangci-lint-1.16.0-linux-amd64.tar.gz" "${tmp}" "tar -C ${build}/.heroku/golangci/bin --strip-components=1 -zxf"
-fi
kind: StorageClass
apiVersion: storage.k8s.io/v1beta1
metadata:
name: encrypted
provisioner: kubernetes.io/aws-ebs
parameters:
type: gp2
encrypted: "true"
Verifying my Blockstack ID is secured with the address 1AWSQztDoP2MnV78edrypjpGV9suHEsuwd https://explorer.blockstack.org/address/1AWSQztDoP2MnV78edrypjpGV9suHEsuwd
package main
import (
"fmt"
"net/http"
"math/rand"
)
func handler(w http.ResponseWriter, r *http.Request) {
fmt.Fprintf(w, "%d", rand.Intn(9999))
@darron
darron / 01lego.yaml
Last active March 8, 2017 18:29
Full Yaml for Kubernetes TLS Ingress with Let's Encrypt Certificates.
apiVersion: v1
kind: Namespace
metadata:
name: kube-lego
---
apiVersion: v1
metadata:
name: kube-lego
namespace: kube-lego
data:
@darron
darron / ecr-empty-repos.sh
Created February 27, 2017 19:16
Figure out which repos in ECR are empty.
export REPOS=$(aws ecr describe-repositories | jq '.repositories | .[].repositoryName' | cut -d'"' -f 2)
for repo in $REPOS;
do
IMAGES=$(aws ecr list-images --repository-name $repo | grep imageDigest)
if [[ "$?" -eq "1" ]]
then
echo "$repo: empty"
fi
done