Skip to content

Instantly share code, notes, and snippets.

View bradfordcp's full-sized avatar

Christopher Bradford bradfordcp

View GitHub Profile
View Makefile
.PHONY: setup
oc project tls-demo
echo "Login to the OpenShift console and install cass-operator and cert-manager operators either globally or within the tls-demo namespace"
.PHONY: setup-issuers
echo "Provisioning self signed certificate issuer and CA with cert-manager"
oc apply -f selfsigned.issuer.yaml
oc apply -f ca.certificate.yaml
View foo.k8ssandracluster.yaml
kind: K8ssandraCluster
name: foo
auth: false
serverType: dse
serverVersion: 6.8.32
bradfordcp / petclinic.asb.yaml
Last active November 13, 2020 21:28
Adding Astra Service Broker to reactive petclinic
View petclinic.asb.yaml
apiVersion: apps/v1
kind: Deployment
name: petclinic-backend
app: petclinic-backend
replicas: 1
View gautodetect
#! /bin/env fish
set NVIDIA_GPU_COUNT (/usr/sbin/lspci | grep -i nvidia | wc -l)
if test "$NVIDIA_GPU_COUNT" -gt 1
echo "Setting graphics to eGPU"
/usr/local/bin/gswitch egpu
echo "Setting graphics to Intel"
/usr/local/bin/gswitch internal-intel
bradfordcp / data.csv
Created March 7, 2020 18:55
Plotly filter example
View data.csv
col1 x y
a -3 -3
a -2 -2
a -1 -1
b 0 0
c 1 1
c 2 2
c 3 3
View gist:cce618e5a72d55f65ea4e9d83e9e9722
bradfordcp@domino ~> crc start -p ~/Downloads/pull-secret --log-level debug
DEBU No new version available, latest version at mirror is 1.0.0-rc.0
INFO Checking if running as non-root
INFO Checking if oc binary is cached
DEBU oc binary already cached
INFO Checking if Virtualization is enabled
DEBU Checking if the vmx/svm flags are present in /proc/cpuinfo
DEBU CPU virtualization flags are good
INFO Checking if KVM is enabled
DEBU Checking if /dev/kvm exists
bradfordcp / Gemfile
Last active September 29, 2017 05:12
Pulls Touch Down stats from
View Gemfile
source ''
gem 'nokogiri'

Keybase proof

I hereby claim:

  • I am bradfordcp on github.
  • I am bradfordcp ( on keybase.
  • I have a public key ASBNKjC6OT8sFez-fWd7Kyg6YfjDr_n3s4wc3YGk6rsYwAo

To claim this, I am signing this object:

bradfordcp /
Last active July 28, 2023 10:10
Setting up Apache Spark to use Apache Shiro for authentication of Spark Master dashboard.

Securing Apache Spark with Apache Shiro

  1. Download shiro-core-1.2.5.jar Apache Shiro Downloads
  2. Download shiro-web-1.2.5.jar Apache Shiro Downloads
  3. Note the location of the JAR files and shiro.ini. I placed it in the root of my Spark download
  4. Update the file with the Shiro JARs and add an entry for the path where the shiro.ini resides
  5. Start the Spark master sbin/
  6. Navigate to the Spark master dashboard
  7. Authenticate with credentials in shiro.ini

Note this was developed / tested with Apache Spark 1.4.1, but should work with newer versions as well.

bradfordcp /
Last active August 29, 2015 14:25
Provides a CLI to manage SSH keys pulled from GitHub in ~/.ssh/authorized_keys.


A CLI tool to add public keys to your host. The keys are pulled via GitHub API.

Listing all keys for the current user

Lists all keys, it will break down keys by GitHub username.

gh_keys list
GitHub Keys: