Example repo demonstrating principal of app container & named Volume to share code between running container services
docker build -t app-container-exmaple .
Now you have an Docker image with your applications source code inside.
This can be run as a container or pushed to a remote registry. eg Docker Hub or Amazon ECR.
docker-compose up -d
docker exec -i dockerappcontainer_php_1 ls /app/www
docker exec -i dockerappcontainer_nginx_1 ls /app/www