Skip to content

Instantly share code, notes, and snippets.

bryfry bryfry

View GitHub Profile
@bryfry
bryfry / main.go
Created Mar 20, 2017 — forked from zupzup/main.go
Go TCP Proxy / Port Forwarding Example (https://zupzup.org/go-port-forwarding/)
View main.go
package main
import (
"flag"
"fmt"
"io"
"log"
"net"
"os"
"os/signal"
@bryfry
bryfry / failing launch
Created Oct 1, 2016
failing launch (10 is not at least 4)
View failing launch
TASK [launch-instance : nginx - os - launch instance] **************************
task path: /home/ubuntu/git/services-ansible/roles/launch-instance/tasks/main.yml:32
Using module file /usr/local/lib/python2.7/dist-packages/ansible/modules/core/cloud/openstack/os_server.py
<127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: ubuntu
<127.0.0.1> EXEC /bin/sh -c '( umask 77 && mkdir -p "` echo $HOME/.ansible/tmp/ansible-tmp-1475290735.9-140508241290004 `" && echo ansible-tmp-1475290735.9-140508241290004="` echo $HOME/.ansible/tmp/ansible-tmp-1475290735.9-140508241290004 `" ) && sleep 0'
<127.0.0.1> PUT /tmp/tmp6xrd2V TO /home/ubuntu/.ansible/tmp/ansible-tmp-1475290735.9-140508241290004/os_server.py
<127.0.0.1> EXEC /bin/sh -c 'chmod u+x /home/ubuntu/.ansible/tmp/ansible-tmp-1475290735.9-140508241290004/ /home/ubuntu/.ansible/tmp/ansible-tmp-1475290735.9-140508241290004/os_server.py && sleep 0'
<127.0.0.1> EXEC /bin/sh -c '/usr/bin/python /home/ubuntu/.ansible/tmp/ansible-tmp-1475290735.9-140508241290004/os_server.py;
@bryfry
bryfry / gzip.go
Last active May 21, 2020
Idiomatic golang net/http gzip transparent compression (works with Alice)
View gzip.go
package main
import (
"compress/gzip"
"io"
"net/http"
"strings"
)
// Gzip Compression
You can’t perform that action at this time.