Skip to content

Instantly share code, notes, and snippets.

View todd-dsm's full-sized avatar
🏗️
Just trying stuff...

Todd Thomas todd-dsm

🏗️
Just trying stuff...
  • smpl-cloud
  • SoCal
View GitHub Profile
@todd-dsm
todd-dsm / install-google-cloud-sdk.sh
Last active May 17, 2023 15:50
Install Google Cloud SDK
# Homebrew
brew install --cask google-cloud-sdk
@todd-dsm
todd-dsm / kubes-getting-started.md
Created April 19, 2023 16:29
Tools to take the first few steps with Kubernetes

Required Kubernetes Programs

First, install some required programs:

  • [homebrew] - always install Homebrew first!
  • [keybase] - used to cryptographically validate the Terraform package
    • macOS: brew install --cask keybase
    • Install it, open it and configure it.
    • Leave keybase running during the Terraform install
  • [Terraform]
@todd-dsm
todd-dsm / tf-debug.log
Created October 20, 2022 17:45
plan fail for hub fleet registration; google_gke_hub_membership does not respect the depends_on argument
2022-10-20T10:43:33.356-0700 [INFO] Terraform version: 1.3.2
2022-10-20T10:43:33.356-0700 [DEBUG] using github.com/hashicorp/go-tfe v1.9.0
2022-10-20T10:43:33.356-0700 [DEBUG] using github.com/hashicorp/hcl/v2 v2.14.1
2022-10-20T10:43:33.356-0700 [DEBUG] using github.com/hashicorp/terraform-config-inspect v0.0.0-20210209133302-4fd17a0faac2
2022-10-20T10:43:33.356-0700 [DEBUG] using github.com/hashicorp/terraform-svchost v0.0.0-20200729002733-f050f53b9734
2022-10-20T10:43:33.356-0700 [DEBUG] using github.com/zclconf/go-cty v1.11.0
2022-10-20T10:43:33.356-0700 [INFO] Go runtime version: go1.19.1
2022-10-20T10:43:33.356-0700 [INFO] CLI args: []string{"/opt/homebrew/Cellar/tfenv/3.0.0/versions/1.3.2/terraform", "fmt", "-recursive=true"}
2022-10-20T10:43:33.356-0700 [DEBUG] Attempting to open CLI config file: /Users/thomas/.terraformrc
2022-10-20T10:43:33.356-0700 [DEBUG] File doesn't exist, but doesn't need to. Ignoring.
@todd-dsm
todd-dsm / environment.zsh
Last active September 27, 2022 23:54
example oh my zsh completion configurations
# file/path: ~/.oh-my-zsh/custom/environment.zsh
# -------------------------------------|------------------------------------- #
# SHELL #
# --------------------------------------------------------------------------- #
alias hist='history | cut -c 8-'
# --------------------------------------------------------------------------- #
# Rust #
# --------------------------------------------------------------------------- #
#source "$HOME/.cargo/env"
@todd-dsm
todd-dsm / tf-diff.tf
Last active February 10, 2022 22:30
IPv6 EKS Cluster
# NETWORKING
resource "aws_vpc" "vpc_network" {
cidr_block = var.host_cidr
enable_dns_hostnames = true
enable_dns_support = true
assign_generated_ipv6_cidr_block = true # REQd
tags = {
"Name" = var.project
"kubernetes.io/cluster/${var.cluster_apps}" = "shared"
@todd-dsm
todd-dsm / list.txt
Created January 19, 2022 19:00
example gist with index
A1 - foo
B2 - bar
C3 - baz
@todd-dsm
todd-dsm / programs.txt
Created January 13, 2022 23:48
Required Programs for DevOps Work
# Some of these programs are target installs; others are installed as dependencies.
# If the purpose of the program is not obvious, it's probably a dependency.
# ---------------------------------------------------------------------------------
autoconf
automake
aws-iam-authenticator
awscli
bash
bazel
bdw-gc
@todd-dsm
todd-dsm / override-values-all.yaml
Created December 13, 2021 21:15
vault values DEFAULT
---
csi:
daemonSet:
annotations: {}
kubeletRootDir: /var/lib/kubelet
providersDir: /etc/kubernetes/secrets-store-csi-providers
updateStrategy:
maxUnavailable: ""
type: RollingUpdate
debug: false
@todd-dsm
todd-dsm / override-values-ref.yaml
Created December 13, 2021 21:13
vault values REFERENCE
---
global:
enabled: true
psp:
annotations: |
seccomp.security.alpha.kubernetes.io/allowedProfileNames: docker/default,runtime/default
apparmor.security.beta.kubernetes.io/allowedProfileNames: runtime/default
seccomp.security.alpha.kubernetes.io/defaultProfileName: runtime/default
apparmor.security.beta.kubernetes.io/defaultProfileName: runtime/default
enable: false
@todd-dsm
todd-dsm / encode-cert.sh
Last active September 13, 2021 20:18
base64 encode certificate; looking for a single line of output, not a block
#!/usr/bin/env bash
{ IFS= read -rd '' secretMaterial <'foo-api.pem';} 2>/dev/null
myEncodedCert="$(echo -n "$secretMaterial" | base64)"
echo "$myEncodedCert"
myEncodedCert is displayed in a text block. I need it in a flat line as the "Target" at the bottom.
---
OUTPUT: Actual