This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gandi.net ssl certificate working with haproxy | |
In one file concatenate the certifcate with the private key (domain.pem in the example) | |
In other file just the intermediate ceritificate (gandi.ca.pem in the example) then in your haproxy.cfg | |
bind *:443 ssl crt /home/.ssh/domain.pem ca-file /home/.ssh/gandi.ca.pem | |
frontend https-in | |
bind *:443 ssl crt /home/.ssh/domain.pem ca-file /home/.ssh/gandi.ca.pem | |
timeout client 1h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"_id": "_design/example", | |
"views": { | |
"foo": { | |
"map": "function(doc){ emit(doc._id, doc._rev)}" | |
} | |
}, | |
"updates": { | |
"lib": { | |
"libjsonpatch": "var jsonpatch;(function(e){function i(e,i){var s=false,o=0,u=i.length,a;while(o<u){a=i[o];var f=a.path.split(\"/\");var l=e;var c=1;var h=f.length;while(true){if(r(l)){var p=parseInt(f[c],10);c++;if(c>=h){s=n[a.op].call(a,l,p,e);break}l=l[p]}else{var d=f[c];if(d.indexOf(\"~\")!=-1)d=d.replace(/~1/g,\"/\").replace(/~0/g,\"~\");c++;if(c>=h){s=t[a.op].call(a,l,d,e);break}l=l[d]}}o++}return s}var t={add:function(e,t){e[t]=this.value;return true},remove:function(e,t){delete e[t];return true},replace:function(e,t){e[t]=this.value;return true},move:function(e,t,n){var r={op:\"_get\",path:this.from};i(n,[r]);i(n,[{op:\"remove\",path:this.from}]);i(n,[{op:\"add\",path:this.path,value:r.value}]);return true},copy:function(e,t,n){var r={op:\"_get\",path:this.from};i(n,[r]);i(n,[{op:\"add\",path:this.path,value:r.value}]);re |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
/* | |
* Script that scrapes google front page | |
* Usage: ./google [<query>] | |
* e.g. ./google hacker news | |
*/ | |
import ( | |
"fmt" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../topeka-elements/theme.html"> | |
<link rel="import" href="../topeka-elements/topeka-resources.html"> | |
<link rel="import" href="../topeka-elements/topeka-app.html"> | |
<link rel="import" href="../ace-element/ace-element.html"> | |
<link rel="import" href="../cool-clock/cool-clock.html"> | |
<link rel="import" href="../chart-js/chart-js.html"> | |
<polymer-element name="my-element"> | |
<template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ vim ~/.tmux.conf | |
set -g mode-mouse on | |
set -g mouse-resize-pane on | |
set -g mouse-select-pane on | |
set -g mouse-select-window on | |
set -g mode-mouse on | |
set -g default-terminal "screen-256color" | |
:x! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lsof -i :9988 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../topeka-elements/theme.html"> | |
<link rel="import" href="../topeka-elements/topeka-resources.html"> | |
<link rel="import" href="../topeka-elements/topeka-app.html"> | |
<polymer-element name="my-element"> | |
<template> | |
<style> | |
:host { | |
position: absolute; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
type User struct { | |
Name string | |
Age int |