Skip to content

Instantly share code, notes, and snippets.

@mattfenwick
mattfenwick / KPNG-windows-hacking.md
Last active August 29, 2022 17:33
Kubernetes resources
git clone [email protected]:kubernetes-sigs/sig-windows-dev-tools.git
cd sig-windows-dev-tools

vagrant destroy --force
make all

vagrant ssh controlplane

@mattfenwick
mattfenwick / calico-cyclonus-notes.md
Last active April 14, 2021 16:13
Calico/Cyclonus -- Apr 14 2021
@mattfenwick
mattfenwick / README.md
Created October 26, 2020 16:48
Running netpol tests on kubernetes source

To run this on Mac

  1. run ./create-calico-kind-cluster.sh

  2. cd path/to/your/kubernetes/repo

  3. run this: (set kubeconfig path appropriately):

make WHAT=test/e2e/e2e.test && \
@mattfenwick
mattfenwick / dns.md
Last active August 10, 2020 11:38
using node-local-dns in kube

Setting up local registry:

for node in $(kind get nodes --name $CLUSTER_NAME); do
  kubectl annotate --overwrite node "${node}" "kind.x-k8s.io/registry=localhost:${reg_port}";
done

In kubernetes/dns repo:

10226 # 1) import components-base into the kubeadm package
10227 # 2) add a few metrics as is done in vi pkg/kubelet/metrics/metrics.go
10228 # 3) run "make kubeadm"
10229 # 4) run "kubeadm init" on your mac
10230 # 5) like this .//_output/local/go/bin/kubeadm init
diff --git a/cmd/kubeadm/app/kubeadm.go b/cmd/kubeadm/app/kubeadm.go
index 1842cfd8cb4..0ab66a1cadb 100644
--- a/cmd/kubeadm/app/kubeadm.go
@mattfenwick
mattfenwick / instructions.md
Last active July 31, 2020 13:26
How to set up the kubernetes dashboard in your cluster
@mattfenwick
mattfenwick / cps.hs
Last active January 4, 2019 15:00
haskell practice
{-# LANGUAGE ScopedTypeVariables #-}
import Prelude (Eq, Num, Int, show, undefined, (==), (<), (>), (.))
import qualified Prelude
id :: ((a -> r) -> r) -> ((a -> r) -> r)
id cx = \k -> cx k
id' :: a -> (a -> r) -> r
@mattfenwick
mattfenwick / cw1.hs
Last active January 3, 2019 13:54
FP practice
-- module Kata (highAndLow) where
import Data.List (sort)
highAndLow :: String -> String
highAndLow input = case (firstAndLast $ sort $ numbers input) of Just (low, high) -> show high ++ " " ++ show low
numbers :: String -> [Int]
numbers = help []
where