Hasura Focuses on Making Kubernetes Easier with GitOps
Kunjan Chauhan set out to reduce waste in India’s food supply chain and help ensure street vendors of fruits and vegetables get a fair deal on the produce they buy. His company, Bompod Solutions, developed a handheld point-of-sale system that even illiterate people could use. The small IoT device can measure the weight and bill entries for the vegetables.
But his developers increasingly were angry with him.
“I like to learn from the field before I build my technology. It’s very iterative. I’m never sure what I’m building, and I keep changing it. So my relationship with developers got very strained. The costs for change was very high. Every time I’d make a change, they’d get very upset,” he said.
About a year and a half ago, one of the developers suggested the Hasura microservices stack, which was designed to help IT teams with little experience with Docker and Kubernetes get started.
“I’m not a tech person; I’m a businessman. Designing is very easy for me. [Setting up the server], maintaining the server, I don’t have to hire anybody for that. Because maintaining clusters is very, very easy with Hasura,” he said.
Making Development Easier
Hasura co-founders Rajoshi Ghosh and Tanmai Gopal originally set out to build a food-delivery marketplace. To save time in building the same components over and over, Gopal assembled a backend and DevOps toolkit called “Procrust.es.” It was a database platform that combined the ease of use of a NoSQL API with the ability to handle transactions.
That toolkit evolved as the pair started a development agency based in Bengaluru, India, and eventually became the Hasura platform, which debuted in February 2017.
“We didn’t start out knowing what the end result would look like. We started with the idea that wanted to make development easier,” Ghosh said.
They created their own version of GraphQL before GraphQL came out, Gopal said and ended up with a GraphQL layer on top of Postgres, which automates that process of providing an API on top of the database to deploy any kind of code without having to build the underlying code for every application.
The Hasura platform gives developers a high-performance data layer (GraphQL and JSON), API gateway with authentication middleware and GitOps automation.
It comes with access control, high performance and scalability.
“The other [things] we developed help make deployment faster,” Gopal said. “The idea is that you want that Heroku-like experience, because it is amazing, but you want that experience in an environment you can control in the enterprise or at scale. So that wound up being a Docker, Kubernetes-based kind of tooling.”
That has been released as an open source project called Gitkube.
”[It] says, ‘Hey, you can take a Docker file, you can take a Kubernetes YAML spec, you can do git push, and get that same experience’ … We’ve made it easier for developers, to onboard them faster. This is kind of all bundled together. That’s the Hasura platform,” Gopal said.
It plans over the next few months to put all its Kubernetes-native components out in open source.
They describe Hasura as PaaS (platform-as-a-service) plus BaaS (backend-as-a-service) that lets you build fast and deploy fast.
You start by creating Hasura project, which employs microservices to automate backend tasks. There are few ready-made microservices such as data, auth and filestore, which give you instant backend APIs you can use in your app directly. Users also can create their own microservices such as an API service or web app.
Hasura also offers language and use-case specific starter kits such as Python, data science or chatbots that eliminate the need to write a lot of boilerplate code.
The second step is to create a Hasura cluster in the cloud to host the Hasura project. For now, it supports DigitalOcean, Google Cloud Platform, AWS and Microsoft Azure and works with customers deploying to others. The platform enables automatic migration among them, it says.
Then the open source tool Gitkube deploys your code as container on your Hasura cluster using git. The configurations, database schema, and your microservices will all be deployed by running git push hasura master.
They call this approach GitOps. Gopal recently spoke about git push at KubeCon + CloudNativeCon 2018 Europe.
“Provided that everything (infrastructure configuration, application dependencies, environment configuration, stateful migrations, tests) is made declarative, git is the only tool that developers need to drive their DevOps tasks,” Gopal said in a blog post.
Using only git reduces the required toolset, he explained, and provides complete extensibility: git-hooks and webhooks allow for infinite customization and tooling to be implemented by operators without affecting developer workflow.
A full-stack developer who learns how to write a Dockerfile and the basics of Kubernetes can take complete control of their stack, end to end, he said. They can build, deploy, operate and scale their microservices application to millions of users entirely by themselves.
“This is unprecedented power. Once this is accessible to people inside enterprises, this will change the dynamic of how applications are built,” he said.
In April, the company, now based in San Francisco and India, announced a $1.6 million seed round led by Nexus Venture Partners along with GREE Ventures.
“Using Hasura’s platform, developers can now create cloud-native, portable and ‘elastic’ applications within a few minutes without knowing anything about Kubernetes in the beginning,” Sameer Brij Verma, managing director of Nexus Venture Partners said at the time.
The Cloud Native Computing Foundation recently named Hasura among 22 new certified Kubernetes vendors. The company has about 40,000 developers on board, according to Gopal.
“Usually it’s the DevOps and sysadmins who are looking at Kubernetes. But eventually, the application developers will be building applications on the Kubernetes substrate. We’re accelerating that process of taking Kubernetes to the application developer,” Ghosh said
“From the perspective of a company, you have a Kubernetes cluster set up with all the automation required to start writing an application from day one and you have access to the underlying layers. … You can slowly get experience with Kubernetes, trying it out because you have those layers and you can use those Kubernetes commands.”
Chauhan said Hasura has worked with him on custom capabilities, such as enabling Realm, which helps you sync across multiple devices.
He used to have to scope out an entire project, rather than a small portion of it because developers were not comfortable building little bits — and he didn’t yet know what he wanted the whole thing to be.
“Now I just show them, ‘This is what a purchase order format looks like,’ this is the API endpoint. Pull the data from here and put it into this table. It’s a very simple API call now. I can visualize every feature in a set of very useful APIs. So this helps me scope out to a more detailed level, and I can work in smaller stints now. I can build small, small features and test them out, then integrate them into the project.”
The Cloud Native Computing Foundation and KubeCon + CloudNativeCon are sponsors of The New Stack.