Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ The action comes with additional options that you can use to configure your proj
| dontautocreate | false | Set this to true if you don't want to automatically create the Heroku app | true or false |
| dontuseforce | false | Set this to true if you don't want to use --force when switching branches | true or false |
| usedocker | false | Will deploy using Dockerfile in project root | true or false |
| docker_heroku_process_type | false | Type of heroku process (web, worker, etc). This option only makes sense when usedocker enabled. Defaults to "web" (Thanks to [singleton11](https://github.com/singleton11) for adding this feature) | web, worker |
| docker_heroku_process_type | false | Type of heroku process (web, worker, etc). This option only makes sense when usedocker enabled. Defaults to "web" (Thanks to [singleton11](https://github.com/singleton11) for adding this feature). Supports the --recursive argument to build and push multiple images by renaming your Dockerfiles to Dockerfile.{process} | web, worker |
| docker_build_args | false | A list of args to pass into the Docker build. This option only makes sense when usedocker enabled. | NODE_ENV |
| appdir | false | Set if your app is located in a subdirectory | api, apis/python |
| healthcheck | false | A URL to which a healthcheck is performed (checks for 200 request) | https://demo-rest-api.herokuapp.com |
Expand Down
4 changes: 3 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,11 @@ const deploy = ({
appdir,
}) => {
const force = !dontuseforce ? "--force" : "";
const recursive = (Object.prototype.toString.call(dockerHerokuProcessType) === '[object String]'
&& dockerHerokuProcessType.indexOf(' ') >= 0) ? "--recursive" : "";
if (usedocker) {
execSync(
`heroku container:push ${dockerHerokuProcessType} --app ${app_name} ${dockerBuildArgs}`,
`heroku container:push ${dockerHerokuProcessType} --app ${app_name} ${dockerBuildArgs} ${recursive}`,
appdir ? { cwd: appdir } : null
);
execSync(
Expand Down