Skip to content

Commit

Permalink
Merge branch 'release/2.5.9' into craft-vite
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Welch committed May 2, 2022
2 parents ec3f32b + 7e7928b commit de9d24a
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 5 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# nystudio107/craft Change Log

## 2.5.9 - 2022.05.02
### Fixed
* Clean up initial check for `composer.lock` or `vendor/autoload.php` to ensure the first-time install is done

### Changed
* Changed `bootstrap.php` to allow `.env`-set environment variables override existing injected environment variables ([#82](https://github.com/craftcms/craft/issues/82))

## 2.5.8 - 2022.04.13
### Fixed
* Changed the hostname from `mysql` to `mariadb` in the `composer_install.sh` and `run_queue.sh` scripts, since we're using MariaDB
Expand Down
2 changes: 1 addition & 1 deletion cms/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

// Load dotenv?
if (class_exists('Dotenv\Dotenv')) {
Dotenv\Dotenv::createUnsafeImmutable(CRAFT_BASE_PATH)->safeLoad();
Dotenv\Dotenv::createUnsafeMutable(CRAFT_BASE_PATH)->safeLoad();
}

// Define additional PHP constants
Expand Down
4 changes: 2 additions & 2 deletions docker-config/php-prod-craft/composer_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
# Ensure permissions on directories Craft needs to write to
chown -R www-data:www-data /var/www/project/cms/storage
chown -R www-data:www-data /var/www/project/cms/web/cpresources
# Check for `composer.lock` & `vendor/`
# Check for `composer.lock` & `vendor/autoload.php`
cd /var/www/project/cms
if [ ! -f "composer.lock" ] || [ ! -d "vendor" ]; then
if [ ! -f "composer.lock" ] || [ ! -f "vendor/autoload.php" ]; then
su-exec www-data composer install --verbose --no-progress --no-scripts --optimize-autoloader --no-interaction
# Wait until the MySQL db container responds
echo "### Waiting for MySQL database"
Expand Down
4 changes: 2 additions & 2 deletions docker-config/php-prod-craft/run_queue.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ until eval "mysql -h mariadb -u $DB_USER -p$DB_PASSWORD $DB_DATABASE -e 'select
do
sleep 1
done
# Wait until the `composer install` is done by looking for the `vendor/autoload.php` file
# Wait until the `composer install` is done by looking for the `vendor/autoload.php` and `composer.lock` files
echo "### Waiting for vendor/autoload.php"
while [ ! -f vendor/autoload.php ] || [ ! -f composer.lock ]
while [ ! -f "vendor/autoload.php" ] || [ ! -f "composer.lock" ]
do
sleep 1
done
Expand Down

0 comments on commit de9d24a

Please sign in to comment.