Sync command from ansible

Sync the base of the command module from the latest ansible. There are a
few fixes in here that relate to python 3.

Change-Id: I474c2dd82bb11c43c52e6bba0507539951579780
1 file changed