When 'keystone token-get' fails, the caller can't detect the failure.
This cause troulbe shooting a bit complicated.
Change-Id: I3c58c5fd0e92a87e87546ea797904e08646a1097
Closes-Bug: #1238412
* moves the image upload logic from stack.sh to functions upload_image()
* tools/upload_image.sh which is a thin wrapper around upload_image()
Change-Id: I8746beebf50cf623b6fe903d6497e66e3fa5dda6