Skip to content

Instantly share code, notes, and snippets.

View benjaminjb's full-sized avatar

Benjamin Blattberg benjaminjb

  • Crunchy Data
  • Texas, US
View GitHub Profile
apiVersion: kyverno.io/v1
kind: ClusterPolicy
metadata:
name: alertmanager
spec:
validationFailureAction: Audit
rules:
- name: deployment
match:
any:
@benjaminjb
benjaminjb / test
Last active November 26, 2021 01:24
{
schemas = https://raw.githubusercontent.com/dhall-lang/dhall-kubernetes/master/1.19/schemas.dhall sha256:9a3cebb878e4c90527ad55db2b344fb706afa0bac87574719d39ba09bdb632f2,
union = https://raw.githubusercontent.com/dhall-lang/dhall-kubernetes/master/1.19/typesUnion.dhall sha256:827f0423034337f5a27b99cb30c56229fa8d35ea58d15a0f5a2d5de66bb86142
}
@benjaminjb
benjaminjb / .dockerignore
Created August 9, 2019 16:28
In the docs folder...
.git
source
// I was confused about what was actually going on with the reconcile loop vis-a-vis the TestReconcile function,
// so I threw some Print statements in and I have some results.
// (Note: the main reconcile loop now calls my reconcileServiceAccount func;
// and one of the first things this test does is create a PSQL parent K8s object.)
serviceaccount := &corev1.ServiceAccount{}
c.Get(context.TODO(), defaultKey, serviceaccount)
fmt.Printf("serviceaccount %+v", serviceaccount.Name)
fmt.Println("")
// Line 8 always prints the name of the serviceaccount
@benjaminjb
benjaminjb / RecipeParserHW.rb
Last active August 29, 2015 14:05
first day hw--a recipe parser
class Recipe
attr_reader :name, :servings, :ingredients
def initialize(name, servings)
@name = name
@servings = servings
@ingredients = []
end
def add_ingredient(i)
@benjaminjb
benjaminjb / banking01.rb
Created July 8, 2014 22:00
MakerSquare Coding Challenge: Banking.rb
class Person
attr_reader :name
attr_accessor :cash
def initialize(name, cash)
@name = name
@cash = cash
puts "Hi, #{@name}. You have $#{@cash}!"
end
end