Skip to content

Instantly share code, notes, and snippets.

@jauderho
jauderho / gist:2b04da39d8a4a359ab0c59793d079d93
Created August 25, 2021 17:30
docker history --no-trunc b78927657a42
IMAGE CREATED CREATED BY SIZE COMMENT
sha256:b78927657a42e26b8cac0b9b8e0a4db006f2d570178f029fd6b1bff015dab4a8 2 weeks ago /bin/bash -c #(nop) SHELL [/bin/bash -c] 0B
<missing> 2 weeks ago /bin/sh -c #(nop) HEALTHCHECK &{["CMD-SHELL" "dig +norecurse +retry=0 @127.0.0.1 pi.hole || exit 1"] "0s" "0s" "0s" '\x00'} 0B
<missing> 2 weeks ago /bin/sh -c #(nop) LABEL url=https://www.github.com/pi-hole/docker-pi-hole 0B
<missing>
KexAlgorithms curve25519-sha256,[email protected]
HostKeyAlgorithms [email protected],ssh-ed25519
Ciphers [email protected]
MACs [email protected],[email protected]
@jauderho
jauderho / PAT
Last active August 17, 2021 06:57
PAT="mypat123"
REPO_URL="https://[email protected]/myorg/myrepo/_git/myrepo"
AUTH=$(echo -n ":$PAT" | openssl base64 | tr -d '\n')
git config --global http.$REPO_URL.extraHeader="Authorization: Basic $AUTH"
git -c http.$REPO_URL.extraheader="Authorization: Basic $AUTH" clone $REPO_URL --no-checkout --branch master
HISTIGNORE="cd *:rm *:curl *:grep *:wget *:ssh *:scp *:sftp *:&"
# Colors
export CLICOLOR=1
export LSCOLORS=gxBxhxDxfxhxhxhxhxcxcx
alias j='jobs'
alias k='kill'
alias more="less"
@jauderho
jauderho / SumGetEventlog.ps1
Created July 25, 2021 22:58
Summary of events using Get-Eventlog
# from https://stackoverflow.com/questions/63804829/powershell-expand-group-object
Get-EventLog -Logname system -EntryType "Error" |
Group-Object 'InstanceID' | Select-Object Count, Name,
@{Name="Message";Expression={$_.Group.Message | select -first 1}} |
Format-Table -Wrap
@jauderho
jauderho / cpustatus.sh
Last active July 21, 2019 14:34 — forked from ecampidoglio/cpustatus.sh
A Bash script that prints the current state of the CPU on a Raspberry Pi. It displays variables like temperature, voltage and speed.
#!/bin/bash
# cpustatus
#
# Prints the current state of the CPU like temperature, voltage and speed.
# The temperature is reported in degrees Celsius (C) while
# the CPU speed is calculated in megahertz (MHz).
function convert_to_MHz {
let value=$1/1000
echo "$value"
@jauderho
jauderho / RDSHCert.ps1
Created March 29, 2017 23:42
PowerShell fragments for automated Let's Encrypt cert request/renew/install for RDP
###################################################################################
# File Name: RDSHCert.ps1 #
# Description: Script to Configure RDSH Certificate in WMI RDP-TCP #
# Version: 1.0 #
# Creator: Ryan Mangan #
# Emails: [email protected] #
# Blog: Ryanmangansitblog.com #
# #
# Date: March 2014 #
# Notes: RDSH Certificate Deployment #
@jauderho
jauderho / Get-SSLThumbprint.ps1
Created March 29, 2017 04:42 — forked from lamw/Get-SSLThumbprint.ps1
Powershell snippet to help extract the SSL Thumbprint (SHA1) of a remote system
Function Get-SSLThumbprint {
param(
[Parameter(
Position=0,
Mandatory=$true,
ValueFromPipeline=$true,
ValueFromPipelineByPropertyName=$true)
]
[Alias('FullName')]
[String]$URL
#!/bin/sh
if [ ! -d "/usr/local/lib" ]; then
echo "Creating directory \"/usr/local/lib\"..."
sudo mkdir "/usr/local/lib"
fi
echo "Downloading \"SUVMMFaker.dylib\"..."
sudo curl -o "/usr/local/lib/SUVMMFaker.dylib" "http://dosdude1.com/sierra/swupatch/SUVMMFaker.dylib"
sudo chmod 755 "/usr/local/lib/SUVMMFaker.dylib"
@jauderho
jauderho / gist:2d12603eeffd0adfc277fa33f744ea09
Last active March 27, 2025 06:48 — forked from lamw/gist:487c9ecb2dc7d043eec8
Automate silent installation of VMware Tools for Mac OS X
#!/bin/bash
# 1 = VMware Tools ISO is mounted from vSphere
# 2 = Download VMware Tools (assumes you can connect to internet)
INSTALL_METHOD=2
C_OPTS="-sL --tlsv1.2 --compressed"
# Thanks to Rich Trouton for tip on Tools being available online
# change things depending on MacOS version