Skip to content

Instantly share code, notes, and snippets.

@dholt
dholt / nvidia-docker-2.yml
Created April 9, 2018 16:59
Simple Ansible playbook for installing nvidia-docker-2 and setting it as the default runtime for Docker
- hosts: all
become: true
become_method: sudo
vars:
daemon_json:
bip: 192.168.99.1/24
default-runtime: nvidia
runtimes:
nvidia:
path: /usr/bin/nvidia-container-runtime
@dholt
dholt / kubespray-vars.yml
Created February 12, 2018 14:09
Kubespray NVIDIA GPU support
## Override Docker install vars to install version compatible with nvidia-docker2
docker_version: '17.03.2'
docker_versioned_pkg:
'17.03.2': docker-ce=17.03.2~ce-0~ubuntu-xenial
docker_package_info:
pkg_mgr: apt
pkgs:
- name: "{{ docker_versioned_pkg[docker_version | string] }}"
@dholt
dholt / gist:c81d423fd3f18bbba93f42e71c1887fe
Created November 6, 2017 17:23 — forked from mattm7n/gist:1405067
Monitor DHCP traffic with tcpdump
# Monitoring on interface eth0
tcpdump -i eth0 -n port 67 and port 68

Keybase proof

I hereby claim:

  • I am dholt on github.
  • I am dholt (https://keybase.io/dholt) on keybase.
  • I have a public key ASCo2hKGa1J_f2GAVThWhQUqu65cmJ-ygfsww6VvRfN47Ao

To claim this, I am signing this object:

@dholt
dholt / fix_smc_hsw_plx.sh
Created August 4, 2016 22:02
Fix Supermicro ACSCtl BIOS issue on Haswell systems
#!/usr/bin/env bash
e=`dmidecode | grep SYS-2028GR-TRT`
if [ $? -ne 0 ] ; then
exit
fi
for i in $(lspci -d "10b5:" | awk '{print $1}') ; do
o=$(lspci -vvv -s $i | grep ACSCtl)
if [ $? -eq 0 ] ; then
set -e
# fw_type will always be developer for Mario.
# Alex and ZGB need the developer BIOS installed though.
fw_type="`crossystem mainfw_type`"
if [ ! "$fw_type" = "developer" ]
then
echo -e "\nYou're Chromebook is not running a developer BIOS!"
echo -e "You need to run:"
echo -e ""