Skip to content

Instantly share code, notes, and snippets.

View celaus's full-sized avatar
🎯
Focusing

Claus Matzinger celaus

🎯
Focusing
View GitHub Profile
@celaus
celaus / AuthenticationConfiguration
Last active August 29, 2015 14:22
JWT-authentication in a proper Authentication HTTP header for Spray (http://spray.io/).
package service.common.config
/**
* Required configuration properties for authentication.
*/
trait AuthenticationConfiguration {
/**
* The secret for signing tokens.
@celaus
celaus / crate-sysinit-debian.sh
Last active September 30, 2015 09:43
Sysinit script for a default debian 7 installation.
#! /bin/bash
### BEGIN INIT INFO
# Provides: crate
# Required-Start: $network $remote_fs $named
# Required-Stop: $network $remote_fs $named
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Starts and stops Crate database server.
# Description: Crate - The distributed database for the age of Docker
### END INIT INFO
<!doctype html>
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!-->
<html class="no-js">
<!--<![endif]-->
<head>
<meta charset="utf-8">
--- index.orig.html 2016-02-01 16:41:32.000000000 +0100
+++ index.html 2016-02-01 16:49:34.000000000 +0100
@@ -44,6 +44,26 @@
<div id="page-viewport" ng-view=""></div>
</div>
</div>
+ <!-- Begin Analytics-->
+<!-- Google Analytics Start -->
+<script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
@celaus
celaus / ga.patch
Last active February 2, 2016 10:59
diff --git a/plugins/crate-admin/_site/index.html b/plugins/crate-admin/_site/index.html
index e930ce9..6025a44 100644
--- a/plugins/crate-admin/_site/index.html
+++ b/plugins/crate-admin/_site/index.html
@@ -44,6 +44,26 @@
<div id="page-viewport" ng-view=""></div>
</div>
</div>
+ <!-- Begin Analytics-->
+<!-- Google Analytics Start -->
[Unit]
Description=crate
After=docker.service
Requires=docker.service
[Service]
TimeoutSec=3600
ExecStart=/bin/bash -c '\
HOSTS=$(fleetctl list-machines --fields=ip --no-legend \
package xyz.x5ff.bklg.data.dao
trait BaseDAO[DomainType] {
def save(obj: DomainType): DomainType
def del(obj: DomainType): DomainType
def createTable(): Any
def dropTable(): Any
}
@celaus
celaus / mopidy-musicbox.conf
Created February 27, 2016 20:07
nginx config for Mopidy's musicbox web client.
location / {
proxy_set_header HOST $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";

Keybase proof

I hereby claim:

  • I am celaus on github.
  • I am clausm (https://keybase.io/clausm) on keybase.
  • I have a public key whose fingerprint is 6E06 8FDF 51A5 84F0 9A6B D81B 5C31 1306 7BDF CE4E

To claim this, I am signing this object:

apiVersion: v1
kind: Service
metadata:
name: crate-discovery
labels:
app: crate
spec:
ports:
- port: 4200
name: crate-web