On CentOS 7, I installed PHP 7.1.
Then I installed composer with:
cd /tmp curl -sS https://getcomposer.org/installer | php71 --> used php71 inste
You need to install the cli package.
yum install php71u-cli is what I needed to do for IUS php.
yum install php71u-cli