I want to be able to use composer install inside my php-fpm container. My current setup:
docker-compose.yml
version: '2'
services:
web:
image: nginx
ports:
- "80:80"
volumes:
- ./public:/var/www/html
- ./vhost.conf:/etc/nginx/conf.d/vhost.conf
fpm:
image: php:fpm
volumes:
- ./public:/var/www/html
expose:
- 9000
composer:
restart: 'no'
image: composer/composer
command: install --working-dir=/var/www/html
volumes_from:
- fpm
But obviously my command: install is happening in the composer container and doesnt have the required php extensions to complete the install.
And composer install inside php-fpm container says composer is not installed
Somehow google doesn't have an answer for this from what I have seen.