Fix script's template to load environment within Rails.root directory