Skip to content

Composer not installed correctly in container #8

Description

@hotdocs

During craftman heroku:prepare I got the following:

sh: 1: /scripts/composer.phar: not found

I worked it to line line 52 of the composer.plugin file:

cm_craft_exec "cd /scripts/composer && /scripts/composer.phar install && /scripts/composer.phar update"

Manually executing the line output the same error:

$> docker exec -t cmtest005_craft_1 sh -c "cd /scripts/composer && /scripts/composer.phar install && /scripts/composer.phar update"
$> sh: 1: /scripts/composer.phar: not found

jumped into cmtest005_craft_1 docker exec -it cmtest005_craft_1 bash and indeed there is no composer.phar in the scripts folder.

root@1e3ae3fae337:/scripts# ls -la
total 7
drwxr-xr-x 6 root root 204 Jun 2 17:59 .
drwxr-xr-x 65 root root 4096 Jun 2 18:48 ..
-rw-r--r-- 1 root root 14 Jun 2 17:37 .gitignore
drwxr-xr-x 4 root root 136 Jun 2 18:49 composer
drwxr-xr-x 7 root root 238 Jun 2 17:40 install
drwxr-xr-x 3 root root 102 Jun 2 17:30 override

From the craftman install done earlier:

===> Running install script 100_composer.sh
stty: stdin isn't a terminal
***> cm_craft_exec: [docker exec -t "cmtest005_craft_1" sh -c "/scripts/install/100_composer.sh"]
stty: stdin isn't a terminal
===> Installing PHP Composer
All settings correct for using Composer
Downloading 1.1.2...
Composer successfully installed to: /composer.phar
Use it: php composer.phar
***> Run composer__configure
***> Run heroku__configure
***> Run mysql__configure
***> Run phpimage__configure
Restarting cmtest005_craft_1 ... done

stty: stdin isn't a terminal indicates the commands in 100_composer.sh didn't execute, right? Given that's the Composer installer it would make sense, but no idea why it might be.

As a reminder I'm on OSX, although I don't think this has anything to do with the host system.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions