negativetwelve / heroku-buildpack-subdir

Deploy apps from subdirectories to Heroku
77 stars 61 forks source link

Issue deploying build pack #3

Closed drusellers closed 7 years ago

drusellers commented 7 years ago
Counting objects: 4688, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (1473/1473), done.
Writing objects: 100% (4688/4688), 779.15 KiB | 31.17 MiB/s, done.
Total 4688 (delta 2438), reused 4601 (delta 2383)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> App not compatible with buildpack: https://github.com/negativetwelve/heroku-buildpack-subdir
remote:        More info: https://devcenter.heroku.com/articles/buildpacks#detection-failure
remote:
remote:  !     Push failed
remote: Verifying deploy...
remote:
remote: !   Push rejected to omc-depot-staging.
remote:
To https://git.heroku.com/omc-depot-staging.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/omc-depot-staging.git'

I don't even see the detection. :(

tree -L 1 -a
.
├── .DS_Store
├── .buildpacks
├── .env
├── .git
├── .gitignore
├── .idea
├── .travis.yml
├── Procfile
├── README.md
├── bin
├── depot-client
├── depot-service
└── depot-ui

any tips?

cat .buildpacks
depot-ui=https://github.com/heroku/heroku-buildpack-nodejs.git
depot-service=https://github.com/heroku/heroku-buildpack-java.git
drusellers commented 7 years ago

PEBKAC

negativetwelve commented 7 years ago

Hi @drusellers, would you mind leaving the solution to whatever your problem was so that it can help others who find this issue? Would save everyone some time and probably pain as well :)

Glad you solved your problem though!

wmaciejak commented 7 years ago

@negativetwelve I had the same issue like @drusellers . I don't have any foggiest idea, but it doesn't work when I deploy by the command git push heroku-app-name master. When I deploy manually by the connecting application with github and pushing button deploy it works properly. Sounds crazy, but it works.

Fun fact - I tested the same behavior with hello world webpack from heroku and I observe the same. Heroku cannot find a file like .buildpacks in the pushed repository(when I make deploy manually it works properly).

drusellers commented 7 years ago

@negativetwelve and @wmaciejak here's what ended up working

cat .buildpacks
depot-ui=https://github.com/heroku/heroku-buildpack-nodejs.git
depot-service=https://github.com/heroku/heroku-buildpack-java.git

THEN in Heroku I needed

image

The key was adding the "runtime" build pack at the end so its available at run time rather than build time

wmaciejak commented 7 years ago

Hmm interesting, thanks! Did you have some problems with running nodejs process? @drusellers

drusellers commented 7 years ago

no i did not - but I only ran it in the "packaging" step vs the run steps - i use node to package my JS