CAUTION: FOR REAL DEV/OPS ONLY!
This repo contains everything you need to:
- set up the Impero PaaS infrastructure from scratch on AWS
- update Impero PaaS infrastructure
- create, deploy, and destroy an application
Impero PaaS infrastructure is built on top of Deis and AWS. Read more about Deis components.
At Impero we have an infrastructure basically composed of two Deis clusters, two MongoDB Replica Set, two PostgreSQL and two AWS Aurora databases, one of each for production
and staging
. Our staging resources are of course reduced at the minimum.
Since Deis is a multi-host clustered PaaS, we can easily scale up when we are running out of resourced on the cluster.
We use a combination of Sentry, Sumologic and Papertrail for logging and data analysis.
Every git repository has two branches master
and development
, production
and staging
respectively.
The idea of the flow is the following:
checkout development
-> app changes
-> local tests
-> commit
-> push development
-> CI tests
-> staging deployment
-> user tests
-> merge development into master
-> local tests
-> push master
-> CircleCI tests
-> production deployment
-> final user tests
Deis consists of a number of components that combine to create a distributed PaaS. Each Deis component is deployed as a container or set of containers. The components are: Controller, Database, Builder, Registry, Logspout, Logger, Publisher, Router, Store.
Losing one of three nodes will have the following effects: Ceph will enter a health warn state but will continue to function. Anything scheduled on the downed node will be rescheduled to the other two nodes. If your remaining nodes don’t have the resources to run the new units, this could take down the entire platform When you scale up to three nodes again, Ceph and Etcd will still think one member is down. You will need to manually remove the downed node from Ceph and Etcd.
Losing two of three nodes will have the following effects: Ceph will enter a degraded state and go into read-only mode. Etcd will enter a degraded state and go into read-only mode. Anything scheduled on the downed node will be rescheduled to remaining node. If your remaining node doesn’t have the resources to run the new units, this could take down the entire platform. When you scale up to three nodes again, Ceph and Etcd will still think two members are down. You will need to manually remove the downed nodes from Ceph and Etcd.
This folder contain the infrastructure provisioning files, both for staging and production clusters.
This folder contain deis units.
This folder has been created to contain deis
and deisctl
respectively. deis
is a “dev” tool, used to deploy and scale applications to a Deis platform. deisctl
is an “ops” tool, used to configure and manage the Deis platform itself.
Scripts helpers for PaaS application management. See instructions.
Blank dockerfiles to use with your web app.
- Deis - Open source PaaS that makes it easy to deploy and manage applications on your own servers
- CoreOS - Minimal operating system that supports popular container systems out of the box
- Fleet - A scheduling backend included with CoreOS
- Docker - Containers wrap up a piece of software in a complete filesystem
- PostgreSQL - Object-relational database system
- Git - Distributed version control system
- Ceph - Distributed object store and file system designed to provide excellent performance, reliability and scalability
- Nginx - HTTP and reverse proxy server
- Logspout - Log routing for Docker container logs