Sorry I'm not that skilled with directadmin.
That's no problem, we all had to learn it at a certain time.
Best is to login via SSH as root, however, you can also use the custombuild plugin if I'm correct.
Login to your server as admin.
Then in the admin screen, scroll down and look under Extra Features. Click on Custombuild there.
Then click on Options.
Then scroll down to PHP Settings. It will look like this:
Now php1_mode defines which mode is used as default by Directadmin and thus also via SSH if you run it as root.
So if you want to have php 8.2 as default version for all installations and thus also in SSH, you have to change php1_release to 8.2.
This means that at this moment most likely 7.3 is as php1_release, you have to set this to php2_release or php3_release.
However, keep in mind that users who are using 7.3 at this moment, must also be set to php3_release after making the change.
When ready then click Save under the php Settings (right side), I guess things will go automatically further there because PHP needs to be rebuild.
Afterwards, suppose you set php 7.3.3 to php3_release then you have to move the users who used php 7.3 to the 3rd option. This can be done via this script (in SSH as root).
Code:
#!/bin/sh
for i in `ls /usr/local/directadmin/data/users/*/domains/*.conf`; do
{
if ! grep -q ^php1_select $i; then
echo php1_select=3 >> $i
continue
fi
perl -pi -e "s/^php1_select=1/php1_select=3/" $i
};
done
exit 0
Once that is done you have to update the config files.
Code:
cd /usr/local/directadmin/custombuild
./build update
./build rewrite_confs
Good luck.