Skip to content

Commit 5847cd4

Browse files
committed
Update docker-compose.yml
1 parent e845d14 commit 5847cd4

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

docker-compose.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ services:
66
depends_on:
77
- database
88
image: '${PHP_IMAGE_NAME}'
9-
container_name: 'cakephp-php-fpm'
9+
container_name: cakephp
1010
networks:
1111
- backend
1212
volumes:
@@ -32,7 +32,7 @@ services:
3232
command: >
3333
bash -c "apt-get -y update && apt-get install -y zip unzip libicu-dev && docker-php-ext-install pdo_mysql intl && pecl install redis && docker-php-ext-enable redis && curl -sS https://getcomposer.org/installer | php && mv composer.phar /usr/local/bin/composer
3434
&& if [ \"$$(ls -A /app/basic)\" ]; then composer update --prefer-dist cakephp/cakephp:~4.0 --working-dir=/app/basic --no-interaction --ignore-platform-req=ext-intl; else composer create-project --prefer-dist cakephp/app:~4.0 basic --working-dir=/app --no-interaction --ignore-platform-req=ext-intl; fi
35-
&& sed -ie \"s/DB_USER/${DB_USER}/; s/DB_PASSWORD/${DB_PASSWORD}/; s/DB_NAME/${DB_NAME}/; s/__SALT__/$$(tr -dc 'A-Za-z0-9!#$$%&()*+,-./:;<=>?@[\]^_`{|}~' </dev/urandom | head -c 32 ; echo)/\" ${WEBSERVER_DOC_ROOT}/app_local.php && cp ${WEBSERVER_DOC_ROOT}/app_local.php /app/basic/config/app_local.php;
35+
&& sed -e \"s/DB_USER/${DB_USER}/;s/DB_PASSWORD/${DB_PASSWORD}/;s/DB_NAME/${DB_NAME}/;s/__SALT__/$$(tr -dc 'A-Za-z0-9!#$$%&()*+,-./:;<=>?@[\]^_`{|}~' </dev/urandom | head -c 32 ; echo)/\" ${WEBSERVER_DOC_ROOT}/app_local.php > /app/basic/config/app_local.php;
3636
grep -qe 'date.timezone = ${LOCAL_TIMEZONE}' ${PHP_INI_DIR_PREFIX}/php/conf.d/security.ini || echo 'date.timezone = ${LOCAL_TIMEZONE}' >> ${PHP_INI_DIR_PREFIX}/php/conf.d/security.ini; php-fpm"
3737
3838
webserver:
@@ -51,6 +51,8 @@ services:
5151
restart: unless-stopped
5252
ports:
5353
- '8080:8080'
54+
links:
55+
- cakephp
5456
environment:
5557
TZ: '${LOCAL_TIMEZONE}'
5658
labels:

0 commit comments

Comments
 (0)