Skip to content

Instantly share code, notes, and snippets.

View lavagetto's full-sized avatar

Giuseppe Lavagetto lavagetto

View GitHub Profile
@lavagetto
lavagetto / check_scap_pybal
Last active August 29, 2015 14:06
Check pybal and scap for inconsistencies
import requests
class bcolors:
OKGREEN = '\033[92m'
WARNING = '\033[93m'

Keybase proof

I hereby claim:

  • I am lavagetto on github.
  • I am joe_ (https://keybase.io/joe_) on keybase.
  • I have a public key whose fingerprint is 2F8E 3636 5355 C419 CAA5 6CFB ECAA FC4A D57B 2BB7

To claim this, I am signing this object:

import etcd
import time
class CachedToken(object)
TTL = 90*86400
key = '/eventlogging/ip_hash'
def __init__(self, ...):
self.c = etcd.Client(..)
self.get()
# Dockerfile
from docker-registry.wikimedia.org/wikimedia-stretch:latest
RUN apt-get update && apt-get -y install mcrouter && rm -rf /var/lib/apt/lists/* \
&& mkdir -p /etc/mcrouter
VOLUME ["/etc/mcrouter"]
CMD ["/usr/bin/mcrouter", "--ssl-port", "11210", "--pem-cert-path=/etc/mcrouter/cert.pem", "--pem-key-path=/etc/mcrouter/key.pem", "--pem-ca-path=/etc/mcrouter/ca.pem", "-f", "/etc/mcrouter/config.json", "--port", "11211"]