Skip to content

Commit efd909b

Browse files
committed
[Fix] Setting back app-volumes because otherwise there are permissions problems when magento folder is not in workdir root
1 parent ec17c5e commit efd909b

File tree

2 files changed

+20
-9
lines changed

2 files changed

+20
-9
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
FROM alpine:latest
2+
3+
RUN mkdir -p /var/www/html && chown -R 1000:1000 /var/www/html
4+
5+
# Keep container running until all other containers are created.
6+
# This avoid issues when this container is started multiple times.
7+
CMD sleep 30

docker-compose-sample.yml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
version: "3"
22

33
services:
4-
5-
phpfpm:
6-
image: modestcoders/php:7.1-fpm
4+
app-volumes:
5+
build: ./config/dockergento/image/app-volumes
76
volumes: &appvolumes
87
- ~/.composer:/var/www/.composer:delegated
98
- sockdata:/sock
@@ -14,10 +13,6 @@ services:
1413
- ./composer.json:/var/www/html/composer.json:delegated
1514
- ./composer.lock:/var/www/html/composer.lock:delegated
1615
# {files_in_git}
17-
environment:
18-
PHP_IDE_CONFIG: serverName=localhost
19-
depends_on:
20-
- db
2116

2217
app:
2318
build: ./config/dockergento/image/nginx
@@ -27,6 +22,15 @@ services:
2722
depends_on:
2823
- phpfpm
2924

25+
phpfpm:
26+
image: modestcoders/php:7.1-fpm
27+
volumes: *appvolumes
28+
environment:
29+
PHP_IDE_CONFIG: serverName=localhost
30+
depends_on:
31+
- app-volumes
32+
- db
33+
3034
db:
3135
image: mysql:5.7
3236
ports:
@@ -43,7 +47,7 @@ services:
4347
image: modestcoders/node-php:node8-php7.1
4448
volumes: *appvolumes
4549
depends_on:
46-
- phpfpm
50+
- app-volumes
4751

4852
unison:
4953
image: modestcoders/unison:2.51.2
@@ -55,7 +59,7 @@ services:
5559
- SYNC_DESTINATION_BASE_PATH=/var/www/html
5660
- SYNC_MAX_INOTIFY_WATCHES=60000
5761
depends_on:
58-
- phpfpm
62+
- app-volumes
5963
privileged: true
6064

6165
volumes:

0 commit comments

Comments
 (0)