Code:grep php /usr/local/directadmin/data/users/*/domains/*.conf
You know what your fist PHP is and second, so assume 1. PHP5 and 2. PHP7
php=ON
php1_select=2 (= PHP7)
php2_select=1 (= PHP5)
it seem sto only show the default php first no matter what domain using. for example ig 5.6 set as#1 and 7.2 as #2 it just lists each domain with the 2 options and shows (no matter what domain set to) the 1 and 2 versions as set in cutombuild.The CMD_CUSTOM_HTTPD page lists the versions, although not sure if it goes on which version the domain is on first..
Some time ago have I written this script:
https://github.com/poralix/directadmin-utils/raw/master/php/change_domain_phpver.sh
The script can be used in bash console to show which PHP version is set for a domain in Directadmin.
You can use the script to change PHP version for a domain from pre-installed with Custombuild 2.0.
More details on usage can be found here: https://github.com/poralix/directadmin-utils/tree/master/php
It's not probably simple in usage when we deal with a bulk of domains, but still it can be used in a loop.
If there is enough interest I could re-write it to a make its usage simpler. Just let me know here or at github.com.
Sure, we mostly work in console. The script was written first for own needs, so it's good if it can be useful for others.
I probably could update the script if you let me know how you want it to work.
Some time ago have I written this script:
https://github.com/poralix/directadmin-utils/raw/master/php/change_domain_phpver.sh
The script can be used in bash console to show which PHP version is set for a domain in Directadmin.
You can use the script to change PHP version for a domain from pre-installed with Custombuild 2.0.
More details on usage can be found here: https://github.com/poralix/directadmin-utils/tree/master/php
It's not probably simple in usage when we deal with a bulk of domains, but still it can be used in a loop.
If there is enough interest I could re-write it to a make its usage simpler. Just let me know here or at github.com.
I found it relatively easy to use and it was easier to use the script than to change php from 50 accounts individuallyWell, it's good. I'd appreciate any feedback on the script usability and functionality. Just let me know how much user-friendly do you find it, and whether or not you would like anything to change.
The script is working fine if to speak about its functionality, i.e. it is doing well what it is designed to do.