2. Who Am I
Mathieu Buffenoir
Co-founder of SBEX & Digithink
VP Bitcoin Association Switzerland
@Mbuffenoir
mathieu@sbex.ch
3. SBEX
SBEX -> Swiss cryptocurrencies broker
(Competitors: coinbase, circle, coinjar, safello ...)
We exchange crypto for fiat (€, CHF)
We create services for our users to store and
send money all around the world cheaply and
instantly
4. Our services
Online bitcoin buying
Our new wallet, multisig
Our remittance project
BTM Network (4 in Switzerland)
6. Follow the “Twelve factor” app recommendations.
In particular:
Scalable, Continuous integration -> Docker
Cloud (Paas) + Hosted in Switzerland -> Exoscale
Choices
7. For developers
Each repo contains:
● 1 Vagrantfile
● 1 Dockerfile
Benefits:
Same env for all devs, plateform independant
Easy onboarding
Using webhooks certains branches are
automatically build by docker hub
8. Environnments
● Prod – Exoscale
multiple instances running several containers,
firewall
● Staging – Exoscale
Production mirror
● Dev – Digital Ocean
One big server that hosts all containers
Docker-compose (ex fig)
9. Prod / Staging
Ansible - docker module:
Pulling containers from private hub
Creating configuration from templates
Starting container
http://docs.ansible.com/docker_module.html
10.
11.
12. 1.Setup DockerHub automated build
2.Push code changes to github / bitbucket
3.DockerHub sees changes and pulls/builds the
image
4.DockerHub calls jenkins webhooks for image
5.DockerHUB module on Jenkins runs tests
Continuous integration
19. Basically it sends to a syslog server all the logs you would normally see in “docker logs”
Your software need to be configured to send logs to stderr/out (This can be tricky!)
Logspout
Logspout is a log router for Docker containers that runs inside Docker. It
attaches to all containers on a host, then routes their logs wherever you
want.
20. Install an ELK cluster in minutes
Start elasticsearch
docker run -d -p 9200:9200 -p 9300:9300 --name es
ehazlett/elasticsearch
Start Logstash
docker run -d --name logstash -p 5000:5000 -p
5000:5000/udp --link es:elasticsearch ehazlett/
logstash -f /etc/logstash.conf.sample
Start Kibana
docker run --name kibana -d -p 80:80 ehazlett/
kibana
21. How is it useful for our business model
We need a network of bitcoin broker around the
world to create a robust and cheap remittance
network
With docker and Paas solutions we can deploy in a
couple hours.
We will open source most of our code in the coming
months
(Making money by selling extra services, as KYC
and compliance tools)
22. Knows problems / new things to try
Ansible docker restart_policy new functionnality
logging driver in docker 1.6
devmapper issue in 1.5
Official docker images can be buggy
Signing / hash of docker images