Skip to content

Instantly share code, notes, and snippets.

View mihok's full-sized avatar

Matthew Mihok mihok

View GitHub Profile
@mihok
mihok / kubernetes-ubuntu-vagrant.rb
Created February 14, 2016 01:28
Vagrant file to create 3 Ubuntu 14.04 machines to run Kubernetes on
$instances = 3
$instance_name_prefix = "kube"
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu/trusty64"
config.ssh.forward_agent = true
(1..$instances).each do |i|
config.vm.define vm_name = "%s-%02d" % [$instance_name_prefix, i] do |config|
config.vm.hostname = vm_name
Timestamp: 2016-03-01 14:09:14.858692027 +0000 UTC
Code: System error
Message: not a directory
Frames:
---
0: setupRootfs
Package: github.com/opencontainers/runc/libcontainer
File: rootfs_linux.go@40
@mihok
mihok / etcd.conf
Last active July 28, 2016 11:26
Vagrant provision script and Upstart service files to install and run etcd
description "etcd Service"
author "Matthew Mihok"
env ETCD_HOME=/opt/etcd-3.0.1
env ETCD_DATA_DIR=/var/lib/etcd
env LOG_HOME=/var/log/etcd
# Run as etcd
setuid vagrant
setgid vagrant
@mihok
mihok / flanneld.conf
Last active July 28, 2016 11:41
Vagrant provision script and Upstart service files to install and run flanneld
description "flanneld Service"
author "Matthew Mihok"
env FLANNELD_HOME=/opt/flanneld-0.5.5
env LOG_HOME=/var/log/flannel
# Make sure network and fs is up, and start in runlevels 2-5
start on (net-device-up
and local-filesystems
and runlevel [2345])
@mihok
mihok / certbot.sh
Created August 7, 2016 15:00
Nginx and Certbot provision scripts
#!/bin/bash
set -x;
apt-get update -y
apt-get install -y gnupg2
cd /opt
# Create our software directory
mkdir certbot
@mihok
mihok / Vagrantfile
Last active August 7, 2016 17:56
Basic Vagrantfile template and base provision script
# -*- mode: ruby -*-
# vi: set ft=ruby :
$instances = 1
$instance_name_prefix = "app"
$app_cpus = 1
$app_memory = 1024
Vagrant.configure(2) do |config|

Keybase proof

I hereby claim:

  • I am mihok on github.
  • I am mihok (https://keybase.io/mihok) on keybase.
  • I have a public key whose fingerprint is 5BC2 BD82 4C67 CF45 8E04 3993 AA94 BFAE 4A92 BF4A

To claim this, I am signing this object:

@mihok
mihok / example.html
Created November 4, 2016 12:59
JSS + ReactJSS is not converting backgroundColor to background-color
<html>
<head>
</head>
<body>
<script type="text/javascript" src="https://unpkg.com/react@15/dist/react.js"></script>
<script type="text/javascript" src="https://unpkg.com/react-dom@15/dist/react-dom.js"></script>
<script type="text/javascript" src="https://unpkg.com/jss@5.5.5/dist/jss.js"></script>
<script type="text/javascript" src="https://unpkg.com/react-jss@4.1.2/dist/jss-compose.js"></script>
@mihok
mihok / .kubeconfig
Last active May 24, 2017 00:24
Vagrant provision script and Upstart service files to install and run kubernetes. As well as the kubernetes dashboard YAML file
apiVersion: v1
clusters:
- cluster:
insecure-skip-tls-verify: true
server: http://44.0.0.103:8888
name: vagrant
contexts:
- context:
cluster: vagrant
namespace: local
@mihok
mihok / daemon.log
Created July 9, 2017 13:18
Minimal Chat's daemon under high load crashes in v0.2
2017/07/09 12:23:39 INFO socket: Incoming client connection EIlq4_OL9VuXfIBbKYCg
2017/07/09 12:23:39 DEBUG store: Storing client.EIlq4_OL9VuXfIBbKYCg ...
2017/07/09 12:23:39 DEBUG store: Storing chat.EIlq4_OL9VuXfIBbKYCg ...
2017/07/09 12:23:39 DEBUG store: Searching for operator. ...
2017/07/09 12:23:39 DEBUG store: Getting operator.steve ...
2017/07/09 12:23:39 INFO socket: Sending 'chat:new' message (1 operators)
2017/07/09 12:23:39 INFO socket: Incoming client connection ll9hoOS7sVtHscdf-27G
2017/07/09 12:23:39 DEBUG store: Storing client.ll9hoOS7sVtHscdf-27G ...
2017/07/09 12:23:39 DEBUG store: Storing chat.ll9hoOS7sVtHscdf-27G ...
2017/07/09 12:23:39 DEBUG store: Searching for operator. ...