Skip to content

Instantly share code, notes, and snippets.

View ybubnov's full-sized avatar

Yakau Bubnou ybubnov

View GitHub Profile
@ybubnov
ybubnov / xterm-256color-italic.terminfo
Created October 21, 2017 07:21 — forked from sos4nt/xterm-256color-italic.terminfo
A xterm-256color based TERMINFO that adds the escape sequences for italic
# A xterm-256color based TERMINFO that adds the escape sequences for italic.
#
# Install:
#
# tic xterm-256color-italic.terminfo
#
# Usage:
#
# export TERM=xterm-256color-italic
#
#!/bin/sh
set -x
port=enp0s8
lladdr=$(ip link show $port | awk '/ether /{print $2}')
sysctl -w net.ipv4.ip_forward=1
ip link add h1-eth0 type veth peer name s1-eth0
ip netns add h1
@ybubnov
ybubnov / 10.2.1.1-consul-after.log
Last active March 28, 2017 12:00
Logs from the consul cluster
==> WARNING: the 'dc' flag has been deprecated. Use 'datacenter' instead
==> WARNING: Expect Mode enabled, expecting 3 servers
==> Starting Consul agent...
==> Starting Consul agent RPC...
==> Consul agent running!
Version: 'v0.7.0'
Node name: '10.2.1.0/24,172.28.5.71,3fc622a3e09b'
Datacenter: 'dc1-3-santa_clara'
Server: true (bootstrap: false)
Client Addr: 0.0.0.0 (HTTP: 8500, HTTPS: -1, DNS: 8600, RPC: 8400)
@ybubnov
ybubnov / main.go
Created February 12, 2017 14:39
Parallel conversion of the numbers to multiple radix
package main
import (
"fmt"
"runtime"
"strconv"
"strings"
)
const (
@ybubnov
ybubnov / Dockerfile
Created January 6, 2017 15:11
Large Docker image
FROM nginx:1.11.8
# Create a 5GiB file to fill the disk space.
RUN fallocate -l 5G /var/lib/large.img
@ybubnov
ybubnov / dodgson.py
Last active August 29, 2015 14:18
Dodgson condensation
import pycuda.autoinit
import pycuda.driver as drv
import numpy as np
import math
import time
from __future__ import division
from pycuda.compiler import SourceModule
""" Dodgson condensation """