Fixes a load issue with specific .env files in Rails apps

Using `Rails.root` returns `nil` before the application boot. This commit solves the issue by determining the Rails root using `File.absolute_path`.