Brickblock had already decided that they wanted Kubernetes. Philip, their CTO, had worked with Kubernetes in previous projects and was aware of the benefits that such a system could deliver to his development team. Important to Philip was ease of operation and the provision of ‘Review Apps’ which allowed each git feature branch to be deployed as a standalone app, enabling a much smoother product / developer workflow.
Brickblock had deployed a Kubernetes cluster to Amazon Web Services using KOPS; a popular method for such deployments. Unfortunately the unmanaged cluster was quite unstable and difficult to wrangle for a team with limited resources. The development team were losing confidence and the CI/CD pipelines were often broken and in need of manual intervention.
Otter Networks was engaged to re-engineer the system into a sustainable and manageable solution suitable for the company’s upcoming production deploys and to hand over ownership to the development team.
The most important decision was to find an effective managed solution for Kubernetes as “rolling their own” is not an acceptable solution for a small, inexperienced team. BrickBlock’s application is mostly stateless as the majority of the data is stored on the Ethereum BlockChain; however, some mission critical data should be highly available using cloud-based PostgreSQL databases. Although offering a somewhat limited set of features, Google Cloud’s Kubernetes offering is by far the best developed and easiest to manage. Luckily, their beta PostgresSQL database service proved to be quite adequate after some rigorous testing.
Google cloud offers an excellent docker registry which integrates will with their GKE solution.
Gitlab and Review Apps
A self hosted Gitlab was chosen as it offers an excellent CI system incorporating Review App functionality. Paired with Kubernetes one can deploy each developer branch into a new, production like environment with an easily accessible URL:
Each push to this branch builds a new docker image and updates Kubernetes. Enabling a much richer communication between Product and Development, these review apps can then be easily shared by Product owners with stakeholders for direct feedback within the development cycle.
The “runners” are configured as an auto-scaling group of Google “preemptible” instances. These instances have a maximum lifetime of 24 hours and are available for approximately 1/3 of the cost of standard instances.
Cost and timeframe
The core solution was delivered within three months for under €30,000. Other ancillary works were undertaken such as general security consulting and other general engineering works. Otter Networks continues to guide BrickBlock on infrastructure matters; negating the need for a full time Devops engineer.
- A cutting edge, micro-services capable infrastructure based on Fully Managed Services
- Very little code or scripts to maintain
- 120% reduction in cloud provider costs
- Fully automated continuous deployment pipelines
- More efficient working with Review Apps