Habitat 0.27.0 Released

We are happy to announce the release of Habitat 0.27.0. We have a number of new features as well as bug fixes, so please read on for all the details. If you just want the binaries, head on over to our downloads page: https://www.habitat.sh/docs/get-habitat/ Thanks again for using Habitat!

Features & Enhancements

Habitat studio update

(Read full details here): in order to improve the local development experience in the studio, we now support artifact caching! The net effect of this change is that users of the Studio should see a substantial reduction in bandwidth usage when building software. A couple of things to note however:

  • The install logic will still (as before) check the Depot to ensure that we still have the latest artifact cached. If a newer artifact exists in the Depot, it will still be downloaded. Therefore, as of this feature, you will still need internet access when running Studio builds. Any potential future “offline” feature would require this caching as a prerequisite which is why it has been implemented first.
  • While an artifact may be pre-cached, the Studio code still needs to install it into the Studio instance, meaning that on-disk extraction and artifact verification is still being performed every time (as before).

Studio Usage Additions: the following new flags and options are added to the hab-studio program which gets called directly on Linux when using hab studio or hab pkg build calls:

  • -N Do not mount the source artifact cache path into the Studio (default: mount the path).
  • -a <ARTIFACT_PATH> Sets the source artifact cache path (default: /hab/cache/artifacts). For non-root users the default will be $HOME/.hab/cache/artifacts.

The following Studio-only environment variables are added:

  • ARTIFACT_PATH - Sets the source artifact cache path (`-a’ option overrides). This is named to line up with the SRC_PATH environment variable already in use.
  • NO_ARTIFACT_PATH - If set, do not mount the source artifact cache path (`-N’ flag overrides).
  • An additional core users function named get_primary_gid_for_user was added to help set correct ownership details on newly created user cache directories. There appears to be no good Windows equivalent call and therefore None is returned which should be correct behavior.

Introduce new optional application.environment qualifier on Service Group

Read full details here. This change adds a new optional qualifier to a Service Group string, called an Application Environment. The printed representation of a Service Group with Application Environment delimited with a hash character and the application name and environment name are delimited with a period character. For example, a Service Group containing an application name “twitter” and environment name of “production” would look like:


The components of the Service Group are as follows:

    twitter   . production  #  redis  . cache

To load a service, 2 new options are added which are used together
(--application/-a and --environment/-e). For example:

hab svc load core/redis \
  --group cache \
  --application twitter \
  --environment production

Add departed state for members

Read full details here. This adds a fourth state for members, ‘Departed’. A departed member is no longer counted as valid for calculating the total population needed for a quorum.

When a member is marked Confirmed, we record the time from the expired thread. When the expired thread runs, it checks for members whose departure time has come; and if it has, it sets their health to
Departed, removes them from the departure timer, and shares the rumor.

This commit sets the departure timer at 72 hours, a particularly conservative number. If an administrator does nothing to bring member back to life in that timeframe, it will be marked departed automatically.

Bug fixes

There are a group of fixes and enhancements made to the Supervisor with this release that should solve some behavioral issues the community has been reporting since the launch of both the Multi-Service Supervisor and then the Launcher. As a result, we strongly recommend upgrading to this Supervisor so you can take advantage of them.

  • Hook-only config updates do not restart services #2448
  • Fix populating @first and @last in eachAlive helper #2831 (reset)
  • Fix populating health of census members #2830 (reset)
  • Fix panic when sending rumors of departed members #2827 (reset)
  • store launcher pid in supervisor lock file #2826 (mwrock)
  • Fix hook compilation and Run hook copying #2808 (reset)
  • Restart services when hook files change #2729 (christophermaier)

There are also some fixes for Studio behavior, which needed to be evolved to match the new capabilities of the Launcher + Supervisor model that we now have.

  • Auto update channel default #2811 (reset)
  • [studio] Kill Launcher process when shutting down Studio. #2809 (fnichol)
  • kill launcher when shutting down windows studio #2812 (mwrock)

And, in what should come to a big relief to some of our Linux users, hab studio rm has been changed so it should never have the ability to delete files outside of the studio.

  • [bug] hab studio rm deletes files outside the studio #1705

Closed issues:

  • Discussion: investigate running IIS applications via Habitat #2124

Merged pull requests: