Skip to content

Instantly share code, notes, and snippets.

What do I need to know?

I need to know how core/scaffolding-node figures out what version of node to use.

Normally, I would expect core/scaffolding-node to have a direct dependency on core/node, but it does not appear to.

core-plans/scaffolding-node/plan.sh

pkg_deps=(core/tar core/jq-static core/rq)

Creating a test app

(Based on this tutorial)

$ express --git my_app
$ cd my_app
$ npm install
$ vim routes/index.js

User creates a new origin through the API like this:

http POST http://localhost:9636/v1/depot/origins Content-Type:application/json Authorization:Bearer:${HAB_AUTH_TOKEN} name=my_new_origin

This goes to builder-depot.

builder-depot

builder-sessionsrv

builder-sessionsrv/src/data_store.rs

use db::pool::Pool;
use db::migration::Migrator;
use hab_net::privilege;
use protocol::sessionsrv;
use postgres;
use protobuf;

Starting Out

  • User is on app.habitat.sh
  • User signs in
  • User clicks on "Origins" in side menu
  • User clicks on a specific origin
  • User clicks on "Upload public origin key"

Builder-Web

Code for "Upload public origin key" button

Stronger (What Doesn't Kill You) - Kelly Clarkson
Somebody Told Me - The Killers
Born this Way - Lady Gaga
The Edge of Glory - Lady Gaga
Scandalous - Mis-Teeq
Lose Yourself - Eminem
Man of La Mancha - Linda Eder
Paradise City - Guns N' Roses
Separate Ways (Worlds Apart) - Journey

Setting up a Github Pages Project Page with Circle CI

Greetings! This will guide you through a basic setup of a Github pages project with Circle CI. All examples here are meant to be as clear as possible - there may be different and quicker ways to do some of these things, but this tutorial is biased on the side of clarity rather than brevity.

Setting up Github Pages with a project

You need a Github repo with an index.html file in it (for an example, check out My personal website. This tutorial assumes you have merge permissions with the repo.

Now, check out this repository to your workstation and create a new gh-pages branch.

11:20:15-nshamrell~/Projects/supermarket/omnibus (add-option-to-configure-s3-url-type)$ kitchen converge default-ubuntu-1204 -l debug
-----> Starting Kitchen (v1.9.0)
D [Vagrant command] BEGIN (vagrant --version)
D [Vagrant command] END (0m0.14s)
D Berksfile found at /Users/nshamrell/Projects/supermarket/omnibus/Berksfile, loading Berkshelf
D Berkshelf 4.3.3 library loaded
D Berksfile found at /Users/nshamrell/Projects/supermarket/omnibus/Berksfile, loading Berkshelf
D Berkshelf 4.3.3 previously loaded
D Berksfile found at /Users/nshamrell/Projects/supermarket/omnibus/Berksfile, loading Berkshelf
D Berkshelf 4.3.3 previously loaded
11:00:01-nshamrell~/Projects/supermarket/omnibus (add-option-to-configure-s3-url-type)$ kitchen converge default-ubuntu-1204 -l debug
-----> Starting Kitchen (v1.8.0)
D [Vagrant command] BEGIN (vagrant --version)
D [Vagrant command] END (0m0.14s)
D Berksfile found at /Users/nshamrell/Projects/supermarket/omnibus/Berksfile, loading Berkshelf
D Berkshelf 4.3.3 library loaded
D Berksfile found at /Users/nshamrell/Projects/supermarket/omnibus/Berksfile, loading Berkshelf
D Berkshelf 4.3.3 previously loaded
D Berksfile found at /Users/nshamrell/Projects/supermarket/omnibus/Berksfile, loading Berkshelf
D Berkshelf 4.3.3 previously loaded
10:45:37-nshamrell~/Projects/supermarket/omnibus (add-option-to-configure-s3-url-type)$ kitchen diagnose --all
---
timestamp: 2016-05-27 17:45:40 UTC
kitchen_version: 1.7.3
plugins:
driver:
Vagrant:
class: Kitchen::Driver::Vagrant
version: 0.20.0
api_version: 2