Skip to content

Instantly share code, notes, and snippets.

@thinktainer
thinktainer / main.go
Last active December 13, 2017 12:51
replace_sql_credential.go
package main
import (
"fmt"
"regexp"
"strings"
)
func main() {
rg := regexp.MustCompile(`.*:\/\/(\S+):(\S+)@.*`)
echo "external_reference:\"1234567890\"\ncorrelation_token:\"18cec3bc-b298-4a75-8a3b-18fa6c251bf6\"\n" | protoc -I=$GOPATH/src --encode=InsuranceSupplyStarted $GOPATH/src/github.com/utilitywarehouse/insurance-proto
buf-model/insurance_supply_events.proto | wc -c
github.com/utilitywarehouse/insurance-protobuf-model/insurance_supply_events.proto: warning: Import google/protobuf/timestamp.proto but not used.
50
interface=lo
bind-interfaces
listen-address=127.0.0.1
address=/dev/127.0.0.1
server=/lan/192.168.100.1
domain=lan,192.168.0.0/24
conf-file=/etc/dnsmasq-dynamic-resolv.conf
resolv-file=/etc/dnsmasq-resolv.conf
#no-resolv
cvt 1600 900 60
xrandr --newmode "1600x900_60.00" 118.25 1600 1696 1856 2112 900 903 908 934 -hsync +vsync
xrandr --addmode eDP-1 1600x900_60.00
version: '2'
services:
zk-1:
image: mrhornsby/zookeeper:latest
expose:
- "2181"
ports:
- "2181:2181"
networks:
net:
interface=lo
bind-interfaces
listen-address=127.0.0.1
address=/dev/127.0.0.1
resolv-file=/etc/dnsmasq-resolv.conf
@thinktainer
thinktainer / Dockerfile
Last active January 23, 2017 15:03
Dockerfile for fakes3 without licence restriction
FROM alpine:3.5
RUN apk update && apk upgrade && apk --update add \
ruby ruby-rake ruby-io-console \
libstdc++ tzdata ca-certificates \
&& echo 'gem: --no-document' > /etc/gemrc \
&& gem install fakes3 -v 0.2.5 \
&& rm -rf /var/cache/apk/*
RUN mkdir -p /srv

Keybase proof

I hereby claim:

  • I am thinktainer on github.
  • I am thinktainer (https://keybase.io/thinktainer) on keybase.
  • I have a public key whose fingerprint is 4D32 6942 F6E5 05DE F3FC 611D 98F4 3563 2DE6 4BCF

To claim this, I am signing this object:

@thinktainer
thinktainer / fiddler_netcat_localhost
Created November 28, 2016 14:33
capture packets to localhost port 3000
sudo tcpdump -c 20 -s 0 -i lo -A host localhost and tcp port 3000
@thinktainer
thinktainer / fiddler_netcat_localhost
Created November 28, 2016 14:33
capture packets to localhost port 3000
sudo tcpdump -c 20 -s 0 -i lo -A host localhost and tcp port 3000