Skip to content

Instantly share code, notes, and snippets.

View kingdonb's full-sized avatar
🚀

Kingdon Barrett kingdonb

🚀
View GitHub Profile
@kingdonb
kingdonb / .gitconfig
Created August 18, 2024 00:21
zsh git aliases
# This is Git's per-user configuration file.
[user]
# name = Your name here
# email = personal@example.com
# signingkey = ABCD1234...
name = Work name
email = hard+worker@example.com
signingkey = 1234FEDC...
[push]
# UNASSIGNED 10.17.13.1 - 10.17.13.2
# UNASSIGNED 10.17.13.225 - 10.17.13.240
# METALLB IPs 10.17.13.241 - 10.17.13.248
# GATEWAY = 10.17.13.249
# moo = 10.17.13.250
# matchbox = 10.17.13.251
# dnsmasq = 10.17.13.252
#
docker run --restart unless-stopped --name=matchbox -d --net=vlan-13net \
@kingdonb
kingdonb / Gemfile
Last active November 5, 2022 20:56 — forked from bf4/Gemfile
Ruby Time and Timezone walkthrough
source "https://rubygems.org"
gem "rack", "~> 1.x"
gem "tzinfo"
gem "webrick"
# Source: https://gist.github.com/0c56f8b8a820198ada44123fa1bf4b60
################################################################
# How To Apply GitOps For Everything Using Crossplane And Flux #
# https://youtu.be/dunU2ABitMA #
################################################################
# Additional Info:
# - eksctl - How to Create and Manage AWS EKS clusters: https://youtu.be/pNECqaxyewQ
# - Flux CD v2 With GitOps Toolkit - Kubernetes Deployment And Sync Mechanism: https://youtu.be/R6OeIgb7lUI
crd = KubeDSL.custom_resource_definition do
metadata do
# name must match the spec fields below, and be in the form: <plural>.<group>
name 'dailies.fluxwebstats.fluxcd.io'
end
spec do
# group name to use for REST API: /apis/<group>/<version>
group 'fluxwebstats.fluxcd.io'
# list of versions supported by this CustomResourceDefinition
version(:v1alpha1) do
@kingdonb
kingdonb / k3d_local_git.sh
Last active May 23, 2023 21:35 — forked from fragolinux/k3d_local_git.sh
complete setup of a local k3d cluster on macos with flux enabled on local git server
#!/usr/bin/env bash
set -m # enable job control
## change your LAN ip address in the variable "PUBLICIP" before run
## run with "-d" command line switch to debug each step, script will wait for keypress to go on
## integrated mods by KingdonB in his fork: https://gist.github.com/kingdonb/dec74f3b74ffbb83b54d53d5c033e508
## added proper coredns patching via "coredns-custom" configmap
## added automatic /etc/hosts file modification if needed, sudo password will be asked in case
## added (commented out) lines to add Flux extra controllers to the setup
$ flux tree ks flux-system
Kustomization/flux-system/flux-system
├── CustomResourceDefinition/alerts.notification.toolkit.fluxcd.io
├── CustomResourceDefinition/buckets.source.toolkit.fluxcd.io
├── CustomResourceDefinition/gitrepositories.source.toolkit.fluxcd.io
├── CustomResourceDefinition/helmcharts.source.toolkit.fluxcd.io
├── CustomResourceDefinition/helmreleases.helm.toolkit.fluxcd.io
├── CustomResourceDefinition/helmrepositories.source.toolkit.fluxcd.io
├── CustomResourceDefinition/imagepolicies.image.toolkit.fluxcd.io
├── CustomResourceDefinition/imagerepositories.image.toolkit.fluxcd.io
@kingdonb
kingdonb / test_output.txt
Created February 15, 2020 20:01
ActiveRecord 6.0.2.1 with the latest composite_primary_keys gem (master), test output on Oracle 18.4.0 (XE)
Finished in 16.489541s, 11.5225 runs/s, 28.3816 assertions/s.
1) Error:
TestDelete#test_destroy_has_many_delete_all:
ActiveRecord::StatementInvalid: OCIError: ORA-00920: invalid relational operator
stmt.c:267:in oci8lib_260.bundle
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/ruby-oci8-2.2.8/lib/oci8/cursor.rb:137:in `exec'
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/activerecord-oracle_enhanced-adapter-6.0.2/lib/active_record/connection_adapters/oracle_enhanced/oci_connection.rb:146:in `exec_update'
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/activerecord-oracle_enhanced-adapter-6.0.2/lib/active_record/connection_adapters/oracle_enhanced/database_statements.rb:152:in `block in exec_update'
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/activerecord-6.0.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:718:in `block (2 levels) in log'
@kingdonb
kingdonb / test_output.txt
Created February 15, 2020 19:02
ActiveRecord 5.2.4.1 with the latest composite_primary_keys gem, test output on Oracle 18.4.0 (XE)
Finished in 9.115729s, 20.8431 runs/s, 53.3144 assertions/s.
1) Error:
TestDelete#test_delete_all_with_join:
ActiveRecord::StatementInvalid: OCIError: ORA-00904: "DEPARTMENTS"."[:department_id, :location_id]": invalid identifier: DELETE FROM "DEPARTMENTS" WHERE (departments.department_id, departments.location_id) IN (SELECT departments.department_id, departments.location_id FROM "DEPARTMENTS" INNER JOIN "EMPLOYEES" ON "EMPLOYEES"."[:department_id, :location_id]" = "DEPARTMENTS"."[:department_id, :location_id]" WHERE (departments.department_id = 1) AND (departments.location_id = 1))
stmt.c:267:in oci8lib_260.bundle
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/ruby-oci8-2.2.8/lib/oci8/cursor.rb:137:in `exec'
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/activerecord-oracle_enhanced-adapter-5.2.8/lib/active_record/connection_adapters/oracle_enhanced/oci_connection.rb:144:in `exec_update'
/Users/kbarret8/.rvm/gems/ruby-2.2.10/gems/activerecord-oracle_enhanced-adapter-5.2.8/lib/active_record/connecti