modified so both instances run using same environment