Sync cliutils from oslo

In the process of unification of the clients code we should
reuse common functionality from Oslo.

Related to blueprint common-client-library-2

Change-Id: Ia5e4e60f07561849f75d88b8a2ea3d23d6d5ff6d
Merge "Sync cliutils from oslo"