Store node details in the JSON datafile

Rather than storing environment variables that show what detail nodes
we may have created have (which we don't do for CI anyway), store the
details of nodes created in the JSON datafile, and make use of those
details in setup-baremetal, if they're set, falling back to the current
environment variables, if they are not.

This previously landed as c2eaf8718a53349044e2210481a462a56f6ad817, but
was reverted, this branch resurrects it, with a change that we store
memory for the nodes in the JSON in the correct units.

Change-Id: I8822c7e04e2f6f5ea5e9ce32bc45a57fdb6c5de6
Co-Authored-By: Robert Collins <rbtcollins@hp.com>