I want the foreman gem to use the PORT value provided in the my development env file instead of using its own values. My files setup is shown below:
A bash script to start foreman:
foreman start -e development.env
The development.env file content:
PORT=3000
The Procfile content
web: bundle exec rails server thin -p $PORT -e $RAILS_ENV $1
The dev server ends up starting on port 5000. I know I can start foreman with --p 3000 to force it to use that port. But that defeats the purpose of the env file.
Any suggestions?