If I run a stack based on Lagoon images, using if (!empty(getenv('LAGOON'))) { incorrectly considers the current runtime as the one that runs in Lagoon cloud.
AFAIK, the purpose of this project is to inject settings for the Lagoon hosted in the cloud rather then "any env where images are used".
I have been successfully using the check
if (!empty(getenv('LAGOON_KUBERNETES'))) {
to then adjust cloud-only settings.