heroku/procfile is the Heroku Cloud Native Buildpack
for applications that use a Procfile to declare process types. It replicates the behavior of Procfile
from builds on the Heroku Platform.
Important
This is a Cloud Native Buildpack, and is a component of the Heroku Cloud Native Buildpacks project, which is in preview.
Note
Before getting started, ensure you have the pack CLI installed. Installation instructions are available here.
To build an application codebase with a Procfile into a production image:
$ cd ~/workdir/sample-procfile-app
$ pack build sample-app --builder heroku/builder:22Then run the image:
docker run --rm -it -e "PORT=8080" -p 8080:8080 sample-appThis buildpack requires a properly formatted Procfile
to exist in the root project directory.
You may configure which process types and commands are included in a build result like this:
# Example Procfile
web: bundle exec rails server -p $PORT
worker: bundle exec rake jobs:workIssues and pull requests are welcome. See our contributing guidelines if you would like to help.
This repository includes a separate guide with exact commands to package the buildpack
and publish it to Amazon ECR: see BUILD_AND_PUBLISH.md.
Quick example (already done for you in CI/local):
aws ecr get-login-password --region us-east-1 \
| docker login --username AWS --password-stdin 348674388966.dkr.ecr.us-east-1.amazonaws.com
pack buildpack package \
348674388966.dkr.ecr.us-east-1.amazonaws.com/neeto-deploy/buildpacks/procfile:5.11.3 \
--config package.toml \
--publishIf you prefer, follow the full instructions in BUILD_AND_PUBLISH.md.