web: Implement a basic REST JSON client

Here's a basic REST JSON client that uses 'text-stream' channels.
It only supports GET requests so far.

We introduce a new namespace for Cockpit called $cockpit. This allows
us to start organizing our code into such a namespace, and getting
ready for foreign code in the same javascript context.

We use jQuery Deferreds as the model for async processing, as this
provides a reliable mechanism for connecting handlers, reporting
failures, progress, etc..

See rest.js near the top for documentation on how to use the REST
JSON client.

Fixes #258