I beleive you are doing CI envrionment handling wrong. You should define CI_ENVIRONMENT environment variable and utilize the respective app/Config/Boot/...php file
';