When deploying Drupal app into 2 instances (apache), DB update has "Racing condition" as "drush updatedb" command runs in both servers

0

Hello

I have an Drupal app. There is an command

 drush updatedb 

in a post-deploy script (with other commands as well).

If I deploy the app into a single instance (of a LB), it is all fine

However if I have two instances (both of them are connected to a db) and run the deployment, I found that there is a race condition of that command in both instances causing the deployment failure

Is there a way to avoid this race condition. I could create just one instance, deploy the app then increase the instances to 2? However, it does not prevent the issue in the future

Many thanks

son
質問済み 2ヶ月前183ビュー
回答なし

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ