mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-02-24 17:52:25 +01:00
There's a service for php but we need to install composer in the php container or worse, install projects' dependencies through composer installed locally. It adds a new service for composer and permit to run composer within a container with just a command: `docker-compose run composer install`.
17 lines
289 B
YAML
17 lines
289 B
YAML
version: "3.1"
|
|
services:
|
|
php:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
volumes:
|
|
- .:/opt/php
|
|
command: ["/opt/php/docker/test_runner.sh"]
|
|
composer:
|
|
image: composer:latest
|
|
working_dir: /app
|
|
volumes:
|
|
- .:/app
|
|
command:
|
|
- install
|