Skip to content

Instantly share code, notes, and snippets.



Block or report user

Report or block mofelee

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
mofelee / k8s-create-deployment.go
Created Nov 9, 2017 — forked from ffledgling/k8s-create-deployment.go
kubernetes client-go example: Create a Deployment based on json
View k8s-create-deployment.go
package main
import (
// We use pretty instead of the common go-spew or pretty-printing because,
// go-spew is vendored in client-go and causes problems
View Linux - Systemd

Linux - Systemd cheatsheet


Activates a service immediately:

systemctl start foo.service

Deactivates a service immediately:

mofelee / Vagrantfile
Created Nov 16, 2017 — forked from anthonysterling/Vagrantfile
Handy Vagrantfile for IE testing with Vagrant.
View Vagrantfile
# Usage: IE={box} vagrant up
# Eg. IE=XPIE6 vagrant up
boxes = {
"XPIE6" => "",
"XPIE8" => "",
"VistaIE7" => "",
"Win7IE8" => "",
"Win7IE9" => "",
mofelee /
Created Sep 25, 2017
Update linux kernel and enable google bbr on ubuntu
# update kernel
dpkg -i linux-image-4.10.0*.deb
# check kernel
uname -a


kubectl port-forward -n kube-system "$(kubectl get -n kube-system pod --selector=weave-scope-component=app -o jsonpath='{}')" 4040


kubectl run kubernetes-bootcamp --port=8080
mofelee / reference.lua
Created Jun 4, 2017 — forked from doches/reference.lua
Lua Cheat Sheet
View reference.lua
-- Lua Cheat Sheet for Programmers, by Al Sweigart
-- This cheat sheet is an executable Lua program.
--[[ This is
a multline comment]]
---[[ This is a neat trick. The first -- makes -[[ not a multiline comment.
print("This line executes.")
--]] The rest of this line is also a comment.
print("Here is a string" .. ' concatenated with ' .. 2 .. ' other strings.')
mofelee / vim_cheatsheet.txt
Created May 16, 2017 — forked from fernandes/vim_cheatsheet.txt
my vim cheatsheet.txt
View vim_cheatsheet.txt
## Vim
### Basic
enable line numbers :set number | :set nu
disable line numbers :set nonumber | :set nonu | :set nu!
enable relative numbers :set relativenumber
convert entire word to uppercace <leader>u
convert entire word to lowercase <leader>l
convert first char of word to uppercase <leader>U
convert first char of word to lowercase <leader>L
View gist:351cee87cda9d60ce87b26a0df57d41b

via (

  • zf#j creates a fold from the cursor down # lines.
  • zf/string creates a fold from the cursor to string .
  • zj moves the cursor to the next fold.
  • zk moves the cursor to the previous fold.
  • zo opens a fold at the cursor.
  • zO opens all folds at the cursor.
  • zm increases the foldlevel by one.
  • zM closes all open folds.
mofelee / varnish
Created Feb 21, 2017 — forked from reifman/varnish
Example Varnish configuration file e.g. /etc/default/varnish
View varnish
# Configuration file for varnish
# /etc/init.d/varnish expects the variables $DAEMON_OPTS, $NFILES and $MEMLOCK
# to be set from this shell script fragment.
# Should we start varnishd at boot? Set to "no" to disable.
# Maximum number of open files (for ulimit -n)
You can’t perform that action at this time.