Deepak3301086
Deepak3301086

Reputation: 487

heroku:ERROR: File '/composer.phar' isn't executable; please 'chmod +x'!

I have a problem when execute git push heroku master

$ git push heroku master
Counting objects: 291, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (278/278), done.
Writing objects: 100% (287/287), 2.95 MiB | 27.00 KiB/s, done.
Total 287 (delta 55), reused 1 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> PHP app detected
remote: -----> No runtime required in composer.json, defaulting to PHP 5.6.4.
remote: -----> Installing system packages...
remote:        - PHP 5.6.4
remote:        - Apache 2.4.10
remote:        - Nginx 1.6.0
remote: -----> Installing PHP extensions...
remote:        - zend-opcache (automatic; bundled)
remote: -----> Installing dependencies...
remote:
remote:  !     ERROR: File '/composer.phar' isn't executable; please 'chmod +x'!

remote:
remote:
remote:  !     Push rejected, failed to compile PHP app
remote:
remote: Verifying deploy...
remote:
remote: !       Push rejected to safe-forest-7658.
remote:
To https://git.heroku.com/safe-forest-7658.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/safe-forest-7658.git'

I also refrenced Error on deploy my app to heroku

I am updateing the composer by 'composer update' and also try 'php composer.hhar update'. But after that this problem occurs.

Upvotes: 1

Views: 1721

Answers (1)

Deepak3301086
Deepak3301086

Reputation: 487

I got solution of this. Actually composer.phar need only first time. so just remove it and run git add . git commit -m 'composer.phar removed' git push heroku master

Upvotes: 5

Related Questions