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
preguntada hace 2 meses183 visualizaciones
No hay respuestas

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas