Docker image with composer 1.0.0 and php7
3.2K
version: '2'
services:
composer:
image: ypereirareis/composer:1.3.2-prestissimo-alpine
working_dir: /src
Add volumes to allow container to access your ssh configuration
version: '2'
services:
composer:
...
volumes:
- ~/.composer/cache:/root/.composer/cache
- ~/.ssh/id_rsa:/var/tmp/id
- ~/.ssh/known_hosts:/var/tmp/known_hosts
- "./:/src"
Add environment variables to allow container to change the owner of generated files
version: '2'
services:
composer:
...
environment:
HOST_GID: ${GID} # Need exporting
HOST_UID: ${UID} # Need exporting
version: '2'
services:
composer:
image: ypereirareis/composer:1.3.2-prestissimo-alpine
working_dir: /src
environment:
HOST_GID: ${GID} # Need exporting
HOST_UID: ${UID} # Need exporting
volumes:
- ~/.composer/cache:/root/.composer/cache
- ~/.ssh/id_rsa:/var/tmp/id
- ~/.ssh/known_hosts:/var/tmp/known_hosts
- "./:/src"
This script will create directory and files into /tmp directory.
Tested on Linux NOT on OSX.
The script install a new fresh symfony app, then run vendors install:
~50s VS ~7s
./compare.sh


Content type
Image
Digest
Size
51.9 MB
Last updated
over 9 years ago
docker pull ypereirareis/composer