setting instance_id in a file for faster access. Fixed issue with this_instance_id not being defined