September 2018
Intermediate to advanced
398 pages
9h 43m
English
How does Heroku know how to execute the application?
Heroku knows how to execute the application by reading the instructions from a file named Procfile, located at the root of the project; the content is as follows:
web: server/target/universal/stage/bin/server -Dhttp.port=$PORT -Dconfig.file=server/conf/heroku.conf
The first indication in the line is the type of application. This can be anything. The web value is a special type, telling Heroku that this process only receives requests from HTTP.
The second part is the path to the executable. In fact, the SBT project creates this executable for us during the build process.
The last part is a list of properties for the Play application, namely
Read now
Unlock full access