Skip to content

Instantly share code, notes, and snippets.

@ewilde
ewilde / linkerd.yaml
Created February 22, 2017 19:30
linkerd configuration
# Do service discovery lookups against the Consul service catalog.
namers:
- kind: io.l5d.consul
includeTag: false
useHealthCheck: false
- kind: io.l5d.fs
rootDir: /opt/linkerd-0.8.6/disco/
routers:
@ewilde
ewilde / linkerd.yaml
Created February 27, 2017 03:52
Lookup consul using path
# Do service discovery lookups against the Consul service catalog.
namers:
- kind: io.l5d.consul
includeTag: false
useHealthCheck: false
routers:
- protocol: http
label: /http-consul
identifier:
kind: io.l5d.path
@ewilde
ewilde / makecrt.sh
Last active April 12, 2017 06:26
create x509 self-signed certificates
#!/bin/bash
set -ex
# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
#
# Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update"
current_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
cn=$1
out_dir=$2
key_file=$cn.key.pem
@ewilde
ewilde / payment_logic
Last active March 20, 2019 07:39
Submitting a payment
let payment_id = xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
let submission_id =xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
result = post payment with payment_id
if result = 409
log warn payment exists
result = post payment_submission with payment_id, submission_id