While the industry is trying to speed up software development and deployment with methodologies like Agile, DevOps and CI/CD, one company believes that tools and solutions that go along with these approaches aren’t changing fast enough.
“Version control is so structured and complex, it takes a lot of time from the software development team,” said Jordi Mon Companys, product manager at Codice Software, makers of the full-stack version control system Plastic SCM. “If we abstract that pain away, we can liberate a lot of that time and allow developers to shorten the release cycle and focus on more creative things.”
To combat this problem, Codice Software has created mergebots, or event-driven automated integrators, for its Plastic SCM system. Mergebots are designed to automatically merge branches once they are reviewed, validated and the test passed. Pablos Santos, CEO and founder of Codice, compares mergebots to robotic automation, but for the integration process.
According to the team, mergebots are independent programs that connect to Plastic SCM through WebSockets.
“Releases became an event, in the bad sense. ‘Hey JM, please, do the integration tomorrow because these two important tasks still need review and we really need them in the next release.’ Sound familiar? You end up delaying the release until tomorrow. Creating new releases was an event. But, if the step was fully automated (this is what DevOps is all about) then a release (or version) would be created today, and a new one tomorrow or in a few hours with the two tasks you were concerned about. No need to wait, no delays, just a continuous flow,” Santos wrote in a post.
Codice has created two types of mergebots: Trunkbot and Conflictsbot. Trunkbot enforces trunk-based development to poll issue trackers for permission to launch builds and run tests, while Conflictsbot is a DevOps remediation bot that notifies users if Plastic SCM is unable to merge branches. According to Companys, Plastic SCM’s mergebots are able to detect and give alerts about merges through the platform’s built-in semantic merge technology.
In addition, users can create custom mergebots for their specific needs. “A mergebot is the logic that drives your daily workflow, so while you can stick to one of the standard ones we’ll be publishing, chances are you’ll need some variations. Things like: once a new release is created, you want a Tweet to be sent automatically to announce it, or you want to automatically create the release notes getting a given Jira field from each task, etc.,” Santos wrote.
However, using version control to automate the DevOps pipeline is not a new phenomenon, according to GitLab’s head of product Mark Pundsack; it is often known as GitOps. “The biggest benefits of using version control to automate your DevOps pipeline are permissions and tracking. For example, you can control who can push to certain branches, and thus control who can trigger pipelines, and you have a record of not only who caused those changes, but a history of everything that has ever been deployed and when,” said Pundsack.
GitLab enables version control and the CI/CD pipeline to work together. CI/CD pipelines are used for various version control events like pushing a commit, merging to the master branch, adding a tag or creating a merge request, Pundsack explained. “CI is a great place to start for automation. You start by automating your testing, and then move into automating your deployments. Most CI really starts from version control as well; CI kicks off when you push up new code to test. It’s logical to continue from there and when you merge to master, not only test your code, but deploy it automatically,” he said. The company also enables users to insert pauses for manual actions if they are not ready to fully automate the pipeline.
Additionally, GitHub has a similar solution in beta called GitHub Actions, which enables developers to implement custom logic to perform specific tasks. “You can combine GitHub Actions to create workflows using an action defined in your repository, a public repository on GitHub, or a published Docker container image. GitHub Actions are customizable and can use the GitHub API and any publicly available third-party APIs to interact with a repository,” according to the company.
“Using version control for a DevOps pipeline doesn’t have to be an all-or-nothing affair. You can start slowly and build up, when your team is ready. Start by making your deployments repeatable, even if they’re manually controlled. Then maybe automatically deploy to staging. Then add automation to deploy to production, but only for specific branches, tags, or after manual actions,” said Pundsack. “When you’re ready, dive into full continuous delivery and have ‘master’ deploy to production on every push. It might seem scary from where you’re at now, but it’s wonderful once you get there.”