Open ubellavance opened 7 years ago
Zend Server 7 has no .phar and no zs-client.sh. Zend Server 8.5 and 9.x do have both. I think that pushing both zs-client
s for ZS7 and do nothing otherwise would be a good solution. Then we would simply always call the zs-client.sh because the zs-client.phar is in different locations.
zs-client.sh
:
#!/bin/sh
. /etc/zce.rc
PHP=$ZCE_PREFIX/bin/php
PHAR_SHARE=$ZCE_PREFIX/share/sdk/zs-client.phar
PHAR_LIB_PATH=`$PHP -r "echo @zend_deployment_library_path('ZendServerSDK');"`
PHAR=$PHAR_LIB_PATH/zs-client.phar
if echo $@ | grep -qE "bootstrapSingleServer|serverAddToCluster|clusterRemoveServer"; then
PHAR=$PHAR_SHARE
elif [ ! -f $PHAR ]; then
PHAR=$PHAR_SHARE
fi
$PHP $PHAR "$@"```
On some version of Zend Server, the API client (zs-client.phar) was not provided with Zend Server itself. Therefore, this module pushed a version of this file. However, this file is now provided but Zend Server and updated if needed. Also, current Zend Server versions provide zs-client.sh, which is a shell that know which .phar to use depending the situation It would be a good thing to: