Streamlining Kubernetes development with Draft

Közzétéve: május 31, 2017

PM Lead, Containers @ Microsoft Azure

I’m Gabe Monroy, the lead PM for containers on Microsoft Azure. I joined Microsoft in April in the acquisition of Deis. At Deis, our team was always laser-focused on making containers easier to use – and easier to deploy on Kubernetes specifically. Now as part of Microsoft, I’m thrilled to continue that mission and share the first piece of open-source software we’re releasing as part of the Azure Container Service team.

Application containers have skyrocketed in popularity over the last few years. In recent months, Kubernetes has emerged as a popular solution for orchestrating these containers. While many turn to Kubernetes for its extensible architecture and vibrant open-source community, some still view Kubernetes as too difficult to use.

Today, my team is proud to announce Draft, a tool that streamlines application development and deployment into any Kubernetes cluster. Using two simple commands, developers can now begin hacking on container-based applications without requiring Docker or even installing Kubernetes themselves.

Draft in action

Draft targets the “inner loop” of a developer’s workflow – while developers write code and iterate, but before they commit changes to version control. Let’s see it in action.

Streamlining Kubernetes

Setting sail for Kubernetes

When developers run “draft create” the tool detects the application language and writes out a simple Dockerfile and a Kubernetes Helm chart into the source tree. Language detection uses configurable Draft “packs” that can support any language, framework, or runtime environment. By default, Draft ships with support for languages including Node.js, Go, Java, Python, PHP, and Ruby.

You can customize Draft to streamline the development of any application or service that can run on Kubernetes. Draft packs are just a simple detection script, a Dockerfile, and a Helm chart.

This simple yet flexible user experience for developers is inspired by PaaS systems like Deis and Cloud Foundry which support the concept of buildpacks. However, Draft differs from buildpack-oriented PaaS systems because it writes out build and deployment configuration into the source tree, making it trivial to construct continuous integration (CI) pipelines that can bring these containers all the way to production.

Edit locally, dev remotely

Once developers run “draft create”, hacking on the application is as simple as typing “draft up”. This ships source code to any Kubernetes cluster (running either locally or in the cloud), builds it in that cluster using the Dockerfile, and deploys it into a dev environment using the Helm Chart. Developers can then test their app live, and any changes in their editor or IDE will be made available in seconds. With a Jenkins registry and a Kubernetes cluster, developers can build on a tight iteration loop from code through deployment, either in concert with an operations team or on their own laptop.

While some developers often start alone, pointing Draft at a Kubernetes cluster running on a laptop, Draft works equally well on a remote Kubernetes cluster. This allows developers to edit code locally, but have their dev environment running in the cloud where they can access all their app’s production dependencies. Three cheers for “dev” and “prod” parity!

Get started today

ACS has a long history of openness including support for multiple orchestrators and the open source ACS-Engine project, which helps customers customize their own ACS cluster. We are proud to extend that open spirit to new projects that help developers succeed with container technology. As of today, Draft is open source and available at https://github.com/Azure/draft. Spin up a Kubernetes Cluster on ACS and take Draft for a test drive today.