Add healthcheck logic for waiting that php service is ready (#448)

This commit is contained in:
Lorenzo Dessimoni
2023-09-14 00:41:39 +02:00
committed by GitHub
parent 3df8a96ab9
commit 70f90033db
3 changed files with 7 additions and 10 deletions

View File

@@ -14,13 +14,13 @@ if [ "$1" = 'php-fpm' ] || [ "$1" = 'php' ] || [ "$1" = 'bin/console' ]; then
composer create-project "symfony/skeleton $SYMFONY_VERSION" tmp --stability="$STABILITY" --prefer-dist --no-progress --no-interaction --no-install
cd tmp
composer require "php:>=$PHP_VERSION"
composer config --json extra.symfony.docker 'true'
cp -Rp . ..
cd -
rm -Rf tmp/
composer require "php:>=$PHP_VERSION"
composer config --json extra.symfony.docker 'true'
if grep -q ^DATABASE_URL= .env; then
echo "To finish the installation please press Ctrl+C to stop Docker Compose and run: docker compose up --build --wait"
sleep infinity