Skip to content

Instantly share code, notes, and snippets.

View ericgreene's full-sized avatar

Eric Greene ericgreene

View GitHub Profile
@ericgreene
ericgreene / split_keyboards.md
Created February 8, 2019 05:03 — forked from itod/split_keyboards.md
Every "split" mechanical keyboard currently being sold that I know of
@ericgreene
ericgreene / cleanup_docker.sh
Created February 1, 2018 22:07 — forked from jaronkk/cleanup_docker.sh
Cleanup and reset docker on Jenkins workers / slaves
#!/bin/bash
# This script should be located on each Jenkins slave, and the jenkins user should have permission to run it with sudo
# Attempts to cleanly stop and remove all containers, volumes and images.
docker ps -q | xargs --no-run-if-empty docker stop
docker ps -q -a | xargs --no-run-if-empty docker rm --force --volumes
docker volume ls -q | xargs --no-run-if-empty docker volume rm
docker images -a -q | xargs --no-run-if-empty docker rmi -f
# Stops the docker service, unmounts all docker-related mounts, removes the entire docker directory, and starts docker again.
@ericgreene
ericgreene / lvm_setup.sh
Last active September 1, 2017 18:20
LVM setup 1 command before fstab
#!/bin/bash
pvcreate /dev/xvdb1;
vgcreate DataGroup00 /dev/xvdb1;
lvcreate -l +100%FREE DataGroup00 -n data;
vgscan;
mkfs.ext4 /dev/mapper/DataGroup00-data;
# add to fstab to mount on boot
echo "/dev/mapper/DataGroup00-data /data ext4 defaults 0 0" >> /etc/fstab;

Keybase proof

I hereby claim:

  • I am ericgreene on github.
  • I am egreene72681 (https://keybase.io/egreene72681) on keybase.
  • I have a public key whose fingerprint is A58D E1D7 BA98 4F02 EB0A A59F 4D8C A4A7 E263 4098

To claim this, I am signing this object:

@ericgreene
ericgreene / Preferences.sublime-settings
Last active December 23, 2015 09:59
Sublime text user settings
{
"color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme",
"font_size": 17.0,
"ignored_packages":
[
"SublimeCodeIntel",
"Vintage"
],
"rulers":
[
@ericgreene
ericgreene / sublime_flake8_lint_settings
Created August 9, 2013 20:40
Settings for sublime flake8 lint package.
{
// run flake8 lint on file saving
"lint_on_save": true,
// popup a dialog of detected conditions?
"popup": true,
// highlight detected conditions?
"highlight": true,
# Ubuntu upstart file at /etc/init/mms-agent.conf
description "MongoDB Monitoring Service (MMS) Agent"
pre-start script
mkdir -p /var/log/mms-agent/
end script
post-stop script
echo "$(date +'%Y-%m-%d %T,000') INFO mms-agent stopped" >> /var/log/mms-agent/agent.log