BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Atlas Workflow and Vagrant Push

Atlas Workflow and Vagrant Push

This item in japanese

Atlas is a new product from Hashicorp, whose main goal is to unify the workflow of moving applications from development to production, by leveraging the suite of open source tools that Hashicorp's been releasing over the years. These include Vagrant, Packer, Terraform and Consul.

Atlas models the application delivery workflow in five main stages.

The five stages of Atlas' workflow.

The developer uses Vagrant to push application code to Packer, which uses it to build an artifact (a fully configured machine image). This artifact is stored in Atlas's Artifact Registry. Terraform then deploys the artifact onto a provider, such as Amazon Web Services. Terraform and Consul will work together to launch services and monitor its health, allowing for auto-scaling and self-healing.

Atlas provides a dashboard that gives you visibility into those five stages. It is broken down into three main areas: Development, Operations and Runtime.

Atlas replaced Vagrant Cloud and the Development area supersedes most of it. You can manage your Vagrant shares, which let you share a running Vagrant environment through the Internet, and lists your Vagrant boxes. You can also register applications so that they are embedded in machine images for later deployment.

Operations gives you access to the "build configurations". They combine the registered applications' code with Packer templates. Packer templates describe the various steps to create an artifact.

The Runtime area contains Terraform's states, which describe the desired state of the infrastructure. It also contains the artifacts, produced by the build configurations, which compose that infrastructure.

The Atlas dashboard, showing the logs of an artifact's build.

One distinctive characteristic of Atlas is the belief on immutable infrastructure. Atlas rests on the principle that you deploy to production entire machine images, the artifacts in Atlas' Artifact Registry. Once you deploy an image, it should not be changed, but replaced by a new one with the intended changes. Hashicorp published its Tao, i.e., its guiding principles, that help to understand the philosophy behind all of its products.

Atlas's docs provide a simple getting started overview. It guides you through a simple workflow iteration, from a blank slate to a fully functioning, AWS-hosted "Hello World" site. It takes about one hour to follow it along, including executing all the workflow's steps.

Atlas is still a free tech preview, and still lacks some features. For instance, the launch and monitor stages are not available yet. Hashicorp says it will complete all the major features and start charging for Atlas in early 2015.

Vagrant Push

Vagrant push is a new feature in Vagrant 1.7, crucial for the Atlas workflow, although it can be used standalone as well. As "vagrant up" creates an application's development environment, "vagrant push" deploys an application, using a variety of strategies. Besides Atlas, Vagrant 1.7 comes with three other strategies: FTP/SFTP, Heroku and Local Exec.

Vagrant push is configured in the Vagrantfile, as any other feature. For instance, using the FTP strategy:

config.push.define "ftp" do |push|
  push.host = "ftp.company.com"
  push.username = "username"
  push.password = "mypassword"
end

Executing "vagrant push" will then upload all the contents of the directory containing the Vagrantfile to "ftp.company.com".

Rate this Article

Adoption
Style

BT