Skip to content

Instantly share code, notes, and snippets.

View fannarsh's full-sized avatar
💭
I may be slow to respond.

Fannar Snær Harðarson fannarsh

💭
I may be slow to respond.
  • Reykjavík, Iceland
View GitHub Profile
@fannarsh
fannarsh / redirect-http.js
Created November 30, 2016 13:42
small thingie that redirects http to https
'use strict'
var http = require('http')
module.exports = function (options) {
var log = options.log
var ports = options.ports
var server = http.createServer()
server.on('request', function (req, res) {
@fannarsh
fannarsh / cloning-rethinkdb-database.md
Last active November 29, 2016 15:46
Clone a rethinkdb database
docker-joyent run -ti --rm gliderlabs/alpine:3.4 /bin/ash
apk add nodejs --no-cache
npm install -g thinker
thinker clone --sh '192.168.129.243:28015' --th '192.168.129.243:28015' --sd connection_store_production --td connection_store_staging
@fannarsh
fannarsh / unifi-docker-setup.md
Created April 25, 2015 01:02
setting up Unifi AP using Controller running in Docker

Putting down some notes, to remember this better next time

When running the Unifi Controller in docker via boot2docker we will experience the problem that auto detection of access-points will not work.
And I really want to be able to use docker for this since I don't want to setup mongodb and java on my laptop.

Using this docker image
https://registry.hub.docker.com/u/jacobalberty/unifi/

running it with

Keybase proof

I hereby claim:

  • I am fannarsh on github.
  • I am fannarsh (https://keybase.io/fannarsh) on keybase.
  • I have a public key whose fingerprint is 0FCB D0BD C859 ABBA 97E8 FD69 72B9 7B9E 576F 2CFA

To claim this, I am signing this object:

@fannarsh
fannarsh / bars in london.md
Last active August 29, 2015 14:08
Top 10 unusual London bars

Ape & Bird

Drink… in a reinvented gastropub with a secret in its cellar.

Some might argue that the pub doesn’t need updating, but if it has to be done, this is the blueprint. The folk behind a small but hugely hip group of bar/ restaurants (Polpo, Spuntino and others) opened this prominent place on Shaftesbury Avenue in late 2013 and labelled it a ‘public house’, but it doesn’t look much like your average Dog & Duck. On the ground floor is a casual restaurant and a separate (almost) traditional drinking space, but the real appeal comes with the downstairs ‘dive bar’, a seductively lit and secretive spot with simple cocktails and high-backed booths for groups. Among the theatres, chains, rip-offs and endless crowds of the West End, this is a highly civilised hideaway.

Essential order: A herbaceous and vivacious southern European digestif – the Aperol Spritz goes down easy.

142 Shaftesbury Avenue, Covent Garden, WC2H 8HJ.

020 7836 3119