Move template and custom path resolution into NodeEnvironment