Unable to run CLI command on OS X/MAMP

Permalink 1 user found helpful
I'm trying to use concrete5 from the command line and I'm running into a fatal error. Any idea on how I can solve this ?

concrete/bin/concrete5 list
Doctrine\DBAL\Driver\PDOException: SQLSTATE[HY000] [2002] No such file or directory in file /web/concrete/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php on line 47
Stack trace:
1. Doctrine\DBAL\Driver\PDOException->() /web/concrete/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:47
| array(1) {
| [0] =>
| string(48) "SQLSTATE[HY000] [2002] No such file or directory"
| }

2. PDOException->() /web/concrete/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:43
| array(1) {
| [0] =>
| string(48) "SQLSTATE[HY000] [2002] No such file or directory"
| }

 
afixia replied on at Permalink Reply
afixia
Event find resolution to this? I'm running in to this myself.
c5dragon replied on at Permalink Reply
c5dragon
Getting this error too when trying to follow the cli tutorial from:
http://documentation.concrete5.org/developers/appendix/cli-commands...

mamp | Concrete5.7.5.9 (not running from updates folder)

Doctrine\DBAL\Driver\PDOException: SQLSTATE[HY000] [2002] No such file or directory in file /Users/Username/Documents/htdocs/development/concrete5.7/concrete/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php on line 47
hissy replied on at Permalink Reply
hissy
You can change the php path in concrete/bin/concrete5

- php -d short_open_tag=On "${SCRIPT_PATH}/concrete5.php" "$@"
+ /Applications/MAMP/bin/php/php7.0.8/bin/php -d short_open_tag=On "${SCRIPT_PATH}/concrete5.php" "$@"
c5dragon replied on at Permalink Reply
c5dragon
This seems to work, thanks. A reason this php path is not picked up automatically?
c5dragon replied on at Permalink Reply
c5dragon
How to adjust this for the v8 version?
c5dragon replied on at Permalink Reply
c5dragon
This message:https://documentation.concrete5.org/developers/installation/upgradin...

Where I added the following line to ‘application/config/database.php’
'unix_socket' =>/Applications/MAMP/tmp/mysql/mysql.sock'