Skip to content

Instantly share code, notes, and snippets.

View coderfi's full-sized avatar

Fairiz 'Fi' Azizi coderfi

View GitHub Profile
Instructions for trying ext4+overlay with docker! In an up-to-date SDK:
Write the following to /build/amd64-usr/etc/portage/package.keywords/overlay
sys-kernel/coreos-sources
sys-kernel/coreos-kernel
sys-fs/btrfs-progs
app-emulation/docker
In src/scripts make the following change to switch to ext4:
/*
* Copyright (c) 2013. Regents of the University of California
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.List;
import java.util.Map;
import java.util.Properties;
import org.apache.avro.io.BinaryDecoder;
import org.apache.avro.io.BinaryEncoder;
import org.apache.avro.io.DecoderFactory;
.timeline {
list-style: none;
padding: 20px 0 20px;
position: relative;
}
.timeline:before {
top: 0;
bottom: 0;
position: absolute;
#!/usr/bin/env bash
# Run this script inside a SVN checkout of the project
authors=$(svn log -q | grep -e '^r' | awk 'BEGIN { FS = "|" } ; { print $2 }' | sort | uniq)
for author in ${authors}; do
echo "${author} = NAME <USER@DOMAIN>";
@coderfi
coderfi / README.md
Last active August 29, 2015 14:07 — forked from agnoster/README.md

agnoster.zsh-theme

A ZSH theme optimized for people who use:

  • Solarized
  • Git
  • Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)

For Mac users, I highly recommend iTerm 2 + Solarized Dark

// This systemd runs iptables-restore on boot:
[Unit]
Description=Packet Filtering Framework
DefaultDependencies=no
After=systemd-sysctl.service
Before=sysinit.target
[Service]
Type=oneshot
ExecStart=/usr/sbin/iptables-restore /opt/docker/scripts/iptables/iptables.rules
upstream some_app_server {
server 127.0.0.1:9393;
}
server {
listen 80;
server_name my-upload-endpoint.com ;
@coderfi
coderfi / ipyD3.py
Last active December 21, 2015 06:39 — forked from z-m-k/LICENSE
Updated for use with iPython 1.0.0 notebook (use the IPython.display.HTML method). Added phantomExec arg to d3object function (defaults to 'phantomjs'... so keep it in your path)
from __future__ import division
import numpy
from uuid import uuid1
class d3object:
def __init__(self,
height=100,
width=100,
topHtml='',
bottomHtml='',
style=None,