Set up environment.