Skip to content

Instantly share code, notes, and snippets.

View mikemrm's full-sized avatar
🪗

Mike Mason mikemrm

🪗
  • Austin, TX
View GitHub Profile
@mikemrm
mikemrm / ks-esxi.cfg
Created April 5, 2019 17:22
Test ESXI
# Accept the VMware End User License Agreement
vmaccepteula
# Set the root password for the DCUI and Tech Support Mode
rootpw --iscrypted $6$xSOpfz11kKe.namH$RbbGJOczPR/k17lPmotNf0cFrmYD7ooWcCuA7/f4xp4Y80g1NvpWJ.UvTvkagmjYmha3xJdEtIxTMWCTaNMf21
# The install media is in the CD-ROM drive
install --firstdisk=lsi_mr3,lsi_msgpt3,vmw_ahci --overwritevmfs
# Set the network to DHCP on the proper network adapter based on its type
network --bootproto=dhcp --device=ec:0d:9a:ca:69:e4
reboot
set base-url http://install.sjc1.packet.net/vmware/esxi-6.5.0
kernel ${base-url}/efi/boot/bootx64.efi -c ${base-url}/boot.cfg ks=https://gist.githubusercontent.com/mikemrm/bf78997a0e569a3cac068e96632fc8d5/raw/7b5501ce2c4c55b048c7705de66f76d8e2044674/ks-esxi.cfg netdevice=ec:0d:9a:ca:69:e4 ksdevice=ec:0d:9a:ca:69:e4
boot
@mikemrm
mikemrm / tailscale-nat.sh
Created January 15, 2022 21:48
tailscale nat
#!/bin/sh
set -e -o pipefail
install_nat(){
local int_iface="$1"; shift
local ext_iface="$1"
if [[ "$(sysctl net.ipv4.ip_forward)" =~ .*0$ ]]; then
echo "Enabling ipv4 forwarding" >&2