Skip to content

Instantly share code, notes, and snippets.

View rossedman's full-sized avatar
🚀
COMPUTERS IN SPACE.

Ross Edman rossedman

🚀
COMPUTERS IN SPACE.
View GitHub Profile
@rossedman
rossedman / dynmotd
Created January 23, 2016 13:29 — forked from cha55son/dynmotd
RHEL (Centos/Fedora) dynamic motd
#!/bin/bash
# Installation:
#
# 1. vim /etc/ssh/sshd_config
# PrintMotd no
#
# 2. vim /etc/pam.d/login
# # session optional pam_motd.so
#
@rossedman
rossedman / consul.service
Last active July 24, 2017 19:30 — forked from yunano/consul.service
Consul Installation
#
# This needs to be installed here:
# /etc/systemd/system/consul.service
#
[Unit]
Description=consul
Requires=network-online.target
After=network-online.target
@rossedman
rossedman / keybase.md
Created September 13, 2016 12:51
keybase prood

Keybase proof

I hereby claim:

  • I am rossedman on github.
  • I am rossedman (https://keybase.io/rossedman) on keybase.
  • I have a public key whose fingerprint is 6712 8DF7 76E3 7227 03EC C55B 1636 1A29 BE1E DAE7

To claim this, I am signing this object:

@rossedman
rossedman / mtg-cards.sh
Last active October 15, 2016 03:08
MTG Cards
#!/bin/bash
#
# Use jq to curl down magic cards into individual files to process into DocumentDB in Azure
#
# List all sets to process
SETS=(MPS KLD DDR CN2 V16 EMN EMA SOI W16 DDQ OGW C15 EXP BFZ DDP V15)
for i in "${SETS[@]}"
do
#!/bin/bash
# this pull and run script on server
# bash <(curl -L tiny.cc/rossedman-ssh)
mkdir ~/.ssh
touch ~/.ssh/authorized_keys
chmod 700 ~/.ssh && chmod 600 ~/.ssh/*
curl https://github.com/rossedman.keys >> ~/.ssh/authorized_keys
echo "rossedman ALL=(ALL) NOPASSWD: ALL" | sudo tee --append /etc/sudoers
@rossedman
rossedman / groupcache.go
Created November 15, 2018 17:54 — forked from fiorix/groupcache.go
Simple groupcache example
// Simple groupcache example: https://github.com/golang/groupcache
// Running 3 instances:
// go run groupcache.go -addr=:8080 -pool=http://127.0.0.1:8080,http://127.0.0.1:8081,http://127.0.0.1:8082
// go run groupcache.go -addr=:8081 -pool=http://127.0.0.1:8081,http://127.0.0.1:8080,http://127.0.0.1:8082
// go run groupcache.go -addr=:8082 -pool=http://127.0.0.1:8082,http://127.0.0.1:8080,http://127.0.0.1:8081
// Testing:
// curl localhost:8080/color?name=red
package main
import (
@rossedman
rossedman / base-image-setup.sh
Last active December 6, 2018 05:02
Base Image Setup
#!/bin/bash
#
# This is meant for setting up a base image in Cubic for homelab
# bootstrapping.
#
# Installing:
# apt-get update -y && apt-get install -y curl wget
# bash <(curl -L $GIST_URL)
#
@rossedman
rossedman / simple.json
Last active December 18, 2018 04:14
Sinple ignition files
{
"ignition": { "version": "2.2.0" },
"passwd": {
"users": [
{
"name": "hankhill",
}
]
}
}
[Unit]
Description=VSCode server for internal network and vpn
After=docker.service
Requires=docker.service
[Service]
TimeoutStartSec=0
Restart=always
ExecStartPre=-/usr/bin/docker stop vscode
ExecStartPre=-/usr/bin/docker rm vscode