soniktrooth Loading the site I was seeing 'deprecated function' errors and realised that I was running a much newer version of php than I should be for this site. So I deleted 8.1 and added 7.4, all very straight forward.
After that, though, it wouldn't serve the site, it would force download the index file instead. So I'm not sure where to go from there.
I have a theory about what might have happened here. When you configured the Nginx site, I'm assuming you would have specifically told it to use PHP 8.1. Then when you deleted the PHP 8.1 service from the rack, it was silently removed from the Nginx site configuration, leaving its PHP config set to "None". If you go back into the site config and set that to 7.4 I'm hoping you'll be in luck.
However, this definitely presents a usability issue. Many people may not initially even realise you can simultaneously run ALL the PHPs simultaneously in one stack if you really want, assigning any version to any site. So it's not like it can fall back to some default if a user deletes one that's in use.
The only solutions I can think of for when you delete a PHP that has been assigned to a site are:
a) Indigo places a warning triangle beside that site and won't start until its config has been re-saved, either with a new PHP version assigned, or "none" selected.
b) ask you to select a new PHP version from those already in your rack (or none) to replace the previous choice for all the sites that had that version chosen.
Neither are great, I fear:
a) has issues with sites being in a state where their PHP config is neither "none" nor a currently valid PHP option. The warning would indicate a problem, but visually the config would be fine.
b) assumes you've already added the new PHP version into your rack, which may not be the case.
Any thoughts on a better workflow around this?