opscode/omnibus-chef — pull request #23 by christophermaier (2012-11-21 11:58:47+00:00)
Title: OC-4709: Add server api version header

This adds an X-Ops-API-Info header to Erchef server responses.

It contains the "flavor" of server (i.e. "osc" or "opc"), the logical
server version (e.g. "11.0.0" for upcoming Chef 11), and the OTP
version of the Erchef release (mainly useful for debugging).

An example:

vagrant@open-source-chef:/srv/piab/mounts/erchef$ curl -I 127.0.0.1:8000/nodes
HTTP/1.1 405 Method Not Allowed
X-Ops-API-Info: flavor=osc;version=11.0.0;erchef=1.0.9
Server: MochiWeb/1.1 WebMachine/1.9.0 (someone had painted it blue)
Date: Wed, 21 Nov 2012 02:37:36 GMT
Content-Length: 0
Allow: GET, POST

(quick-and-dirty test with an unauthenticated request, but you get the picture.)

This has been confirmed on Omnibus builds of both Erchef servers.