app config/envs refactoring