Skip to content

StasKoval/babushka-deps

 
 

Repository files navigation

Icelab Development Environment

Babushka deps for building the standard Icelab Mac OS X development environment.

Requirements

  • OS X (10.9 Mavericks or 10.10 Yosemite)
  • Latest available version of Xcode

Install

First time

First, prepare your system. You must follow these steps if you have an existing Homebrew installation, Ruby or Node.js version managers, or custom dotfiles in your home directory. After you've done this, open a new shell.

Install Babushka:

sudo sh -c "`curl https://babushka.me/up`"

You'll be asked where to install Babushka. Accept the default value of /usr/local/babushka.

Then, apply our Babushka deps. If you're running this for the very first time, you need to apply a bootstrapping dep first:

babushka "icelab:workstation bootstrapped"

You'll be prompted for some things:

  1. To enter your user password.
  2. To enable write access to /usr/local for admin users.

It's OK to comply with both of these.

After this has completed, open a new shell and then finish applying the rest of the deps:

babushka "icelab:workstation"

Finally, enable our private dep source for cloning and setting up Icelab projects (you can skip this if you're a public user these Babuhska deps):

babushka "icelab:projects"

Updates

To update your environment, first update the Babushka sources:

babushka sources -u

Then apply our deps again:

babushka "icelab:workstation"

What it sets up

These Babushka deps are nothing magical. They are merely a collection of jobs that bring your system environment up to a known state by installing things and running shell commands.

The resulting environment, therefore, is nothing special. It is a vanilla OS X web development environment. You should endeavour, therefore, to understand and learn the tools that are installed, so you can work with them directly after they are in place.

Your environment

Zsh is your default shell, and the Icelab dotfiles provide a common baseline shell environment. These are managed using rcm and can be combined with another dotfiles directory for personal customization. See the README for more information.

rbenv and ruby-build manage and install your Ruby versions. The most recent stable Ruby version is your default.

nodenv and node-build for managing and installing Node.js versions. The most recent stable Node.js version is your default.

Your system

Homebrew is installed in /usr/local for installing and managing system packages.

The following system services are installed via Homebrew and already running:

The brew services command is available for managing these services (run brew help services for more information).

These utilities are also installed:

Enable development for particular Icelab projects

As part of this set up, a (private) "projects" Babushka source is installed in ~/.babushka/sources/projects. This source contains deps to check out various Icelab projects.

To see the available projects, run babushka list projects and look for the names under the "# projects (remote)" heading.

To activate the development environment for any one of our projects, run babushka projects:<project_name>, replacing the name with anything you saw in the babushka list output.

Activating the development environment for a project does the following:

  1. Checks the project out into ~/src/<project_name>
  2. If specified, the project's own Babushka dep is run, making whatever changes are necessary to enable development on the project. This dep will be available in the babushka-deps/ directory at the top-level of the project's codebase.

Enable experimental features

These deps ship with a few experimental features not yet part of the standard workstation environment.

Buildkite agent

Run the agent for Buildkite builds on your machine:

babushka "icelab:buildkite-agent"

Docker on OS X, via Dinghy

Run apps on your machine using Docker and Docker Compose.

babushka "icelab:docker"

Customize your environment with Babushka

If you want to automate your personal system customizations, you can write your own Babushka deps and have them work alongside these ones.

First, make sure you have a space for your personal Babushka source:

mkdir -p ~/.babushka/deps

Then create a dep that requires icelab:workstation, along with any other personal deps that you'd like to use, e.g. in ~/.babushka/deps/laptop.rb:

dep "laptop" do
  # Build the standard Icelab environment
  requires "icelab:workstation"

  ### Personal deps can follow

  # I prefer wget
  requires "wget.managed"
end

dep "wget.managed"

Then, running babushka laptop will ensure the Icelab development environment stays updated alongside all of your customizations.

To share your deps, turn ~/.babushka/deps into a git repo and push it up to https://github.com/<your_username>/babushka-deps.git. See Tim's Babushka deps as an example.

Credits

Babushka is a wonderful automated computing system from Ben Hoskings.

These deps are maintained by Icelab.

About

Icelab standard development environment

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%