In a terminal start a server.
$ python -m SimpleHTTPServer 8000
In another terminal set up the cgroups freezer.
-- Let's say you have a table full of work: | |
CREATE TABLE tasks ( | |
id UUID PRIMARY KEY NOT NULL DEFAULT gen_random_uuid(), | |
status TEXT NOT NULL DEFAULT 'pending', | |
payload JSON NOT NULL, -- or just have meaningful columns! | |
created_at TIMESTAMP NOT NULL DEFAULT NOW() | |
); |
In a terminal start a server.
$ python -m SimpleHTTPServer 8000
In another terminal set up the cgroups freezer.
# Given a long-running process in the terminal: | |
# | |
# - Ctrl+Z to suspend it | |
# - Run `keep-track` | |
# - Output resumes, when done will show a notification with the time it took for the process to run | |
# | |
# Can be customized with an `--icon` to `notify-send`, | |
# maybe a sound effect added in the `&&` list. | |
# | |
function keep-track() { |
Audience: anyone in the BOSH ecosystem, whether you work on something open-source or proprietary
"BOSH Links" is a feature which simplifies how data is shared between BOSH-deployed jobs that need to collaborate with one another (e.g. a web server and its backing database). Like many BOSH things, the whole "BOSH Links" thing can seem counter-intuitive at first, and it may not be clear why things are the way they are. This note hopes to show some of the powerful benefits of BOSH Links, and provide examples and explanations that make things more intuitive.
See our wiki page
Locate the section for your github remote in the .git/config
file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/*
to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:
# | |
# This file should be in .../cookbooks/database/templates/default/database.yml.erb | |
# | |
<%= @environment %>: | |
adapter: <%= @adapter %> | |
database: <%= @database %> | |
username: <%= @username %> | |
password: <%= @password %> | |
host: <%= @host %> |
require 'faraday' | |
require 'net/http' | |
require 'pp' | |
# Repos: | |
# https://github.com/technoweenie/faraday | |
# https://github.com/pengwynn/faraday_middleware | |
# Blog posts: | |
# http://adventuresincoding.com/2010/09/writing-modular-http-client-code-with-faraday |