Step 10: Auto-update the running application

Build System Demo

Suppose we've been working on the sample app. Let's increment the version and trigger a new build.

Edit the plan.sh file in your forked GitHub repo (as we did earlier) by clicking the pencil icon.

Change the value of pkg_version from 1.0.1 to 1.0.2, then use the Commit changes button to update the master branch.

Habitat Builder will detect the change and start a new build automatically. You can view the resulting output in the Habitat Builder web app. Once the build job completes, re-run the docker commands to verify the updated container:

$ docker pull your-docker-org/your-docker-repo
$ docker run -it -p 8000:8000 your-docker-org/your-docker-repo

Preview the application in your browser

With the container runnning, visit http://localhost:8000/and see the new version of the sample app.

That's a wrap!

By deploying your application with Habitat, you are now able to take advantage of all that Habitat has to offer. Here, you learned how to set up automated builds and publish your application to a container registry.

In the Process Supervisor demo, you will get a taste for what comes built-in with your newly packaged application.

Return to the Learn Habitat page for additional demos and tutorials.