Changed to disbale features if environment variables or substitue not available.