Skip to content

Instantly share code, notes, and snippets.

View infamousjoeg's full-sized avatar
🙊
I'm really good at keeping secrets.

Joe Garcia infamousjoeg

🙊
I'm really good at keeping secrets.
View GitHub Profile
@infamousjoeg
infamousjoeg / debugging_info.md
Created February 24, 2022 16:34 — forked from micahlee/debugging_info.md
Conjur K8s Authenticator Debugging
  • Display role bindings for conjur-cluster service account token

    oc get clusterrolebindings -o json \
      | jq '.items | map(select(any(.subjects[]; .name | contains("conjur-cluster"))))'
    
  • Display conjur-authenticator role information

    oc describe clusterrole conjur-authenticator
    
@infamousjoeg
infamousjoeg / Helper.cs
Created January 31, 2022 19:17 — forked from rbrayb/Helper.cs
Validating an ADFS JWT token
using System;
using System.Threading;
using System.Threading.Tasks;
namespace ValidateJWTConsoleApp
{
class Helper
{
internal static class AsyncHelper
{
@infamousjoeg
infamousjoeg / package-vagrant-box.sh
Last active January 28, 2022 17:31 — forked from srijanshetty/package-vagrant-box.md
Clean up a vagrant box before packaging
#!/bin/bash
# We’re now going to clean up disk space on the VM so when we package it into a new Vagrant box, it’s as clean as possible. First, remove APT cache
sudo apt-get clean
# Then, “zero out” the drive (this is for Ubuntu):
sudo dd if=/dev/zero of=/EMPTY bs=1M
sudo rm -f /EMPTY
# Lastly, let’s clear the Bash History and exit the VM:

MySQL Download URL

https://dev.mysql.com/get/Downloads/MySQL-5.5/mysql-5.5.56-linux-glibc2.5-x86_64.tar.gz

Open the terminal and follow along:

  • Uninstall any existing version of MySQL
sudo rm /var/lib/mysql/ -R
@infamousjoeg
infamousjoeg / add CA cert on CentOS.md
Created March 20, 2018 17:18 — forked from kekru/add CA cert on CentOS Debian Ubuntu.md
Add CA cert to local trust store on CentOS or Debian
  • Open a webpage that uses the CA with Firefox
  • Click the lock-icon in the addressbar -> show information -> show certificate
  • the certificate viewer will open
  • click details and choose the certificate of the certificate-chain, you want to import to CentOS
  • click "Export..." and save it as .crt file
  • Copy the .crt file to /etc/pki/ca-trust/source/anchors on your CentOS machine
  • run update-ca-trust extract
  • test it with wget https://thewebsite.org
@infamousjoeg
infamousjoeg / interfaces
Last active April 27, 2018 14:32 — forked from takipone/interfaces
Debian/Ubuntu /etc/network/interfaces
auto lo
iface lo inet loopback
auto ens160
iface ens160 inet static
address IP_ADDR
netmask NETMASK
gateway DEFAULT_GATEWAY
dns-nameservers DNS
@infamousjoeg
infamousjoeg / Linux Static IP
Created February 13, 2018 21:26 — forked from fernandoaleman/Linux Static IP
How To Configure Static IP On CentOS 6
## Configure eth0
#
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
NM_CONTROLLED="yes"
ONBOOT=yes
HWADDR=A4:BA:DB:37:F1:04
TYPE=Ethernet
BOOTPROTO=static
@infamousjoeg
infamousjoeg / PowerShell Customization.md
Created February 6, 2018 14:40 — forked from jchandra74/PowerShell Customization.md
PowerShell, Cmder / ConEmu, Posh-Git, Oh-My-Posh, Powerline Customization

Pimping Up Your PowerShell & Cmder with Posh-Git, Oh-My-Posh, & Powerline Fonts

Backstory (TLDR)

I work as a full-stack developer at work. We are a Windows & Azure shop, so we are using Windows as our development platform, hence this customization.

For my console needs, I am using Cmder which is based on ConEmu with PowerShell as my shell of choice.

Yes, yes, I know nowadays you can use the Linux subsystem on Windows 10 which allow you to run Ubuntu on Windows. If you are looking for customization of the Ubuntu bash shell, check out this article by Scott Hanselman.

@infamousjoeg
infamousjoeg / README.md
Created February 2, 2018 23:09 — forked from leosuncin/README.md
Install Powerline on Debian/Ubuntu
  1. Install pip sudo apt-get install python-pip or wget https://bootstrap.pypa.io/get-pip.py && sudo python get-pip.py
  2. Install powerline sudo pip install powerline-status
  3. Download and install fonts git clone https://github.com/powerline/fonts.git && cd fonts && sh ./install.sh
  4. Add this lines to respective file
    .vimrc

set rtp+=/usr/local/lib/python2.7/dist-packages/powerline/bindings/vim/
> " Always show statusline

@infamousjoeg
infamousjoeg / incept-minikube.sh
Created January 29, 2018 16:03 — forked from osowski/incept-minikube.sh
Install Minikube, Kubectl, and Virtualbox on Ubuntu
#Installing VirtualBox
echo "Installing VirtualBox........................"
sudo apt-get install virtualbox
#Installing kubectl https://kubernetes.io/docs/getting-started-guides/kubectl/
echo "Installing kubectl..........................."
wget https://storage.googleapis.com/kubernetes-release/release/v1.4.4/bin/linux/amd64/kubectl
chmod +x kubectl
sudo mv kubectl /usr/local/bin/kubectl