From 4d70c67c43a04662f614a1a8cc00d4e8f13e4fe2 Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Thu, 29 Oct 2020 12:10:44 +0000 Subject: [PATCH] Only run if there is no built flag --- .ddev/commands/web/app | 1 + .ddev/config.yaml | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.ddev/commands/web/app b/.ddev/commands/web/app index 0af25391c..ea6d40d75 100755 --- a/.ddev/commands/web/app +++ b/.ddev/commands/web/app @@ -14,6 +14,7 @@ case $1 in install) drush site:install -y --account-pass=admin123 --existing-config drush user:login + touch .flag-built ;; refresh) diff --git a/.ddev/config.yaml b/.ddev/config.yaml index 5e1b6242b..052d216b8 100644 --- a/.ddev/config.yaml +++ b/.ddev/config.yaml @@ -11,8 +11,8 @@ additional_fqdns: [] provider: default hooks: post-start: - - composer: install - - exec-host: ddev theme development + - exec: "[[ ! -f .flag-built ]] && composer install || exit 0" + - exec-host: "[[ ! -f .flag-built ]] && ddev theme development || exit 0" post-import-db: - exec: drush sql-sanitize -y --sanitize-password=password - exec: drush cr