@Javier "Ciberman" Mora , Apologies for the delay from over the weekend.
I would suggest you leverage Azure Startup (under ‘Configuration’ in the portal target, Startup command.
The easiest way to run database migrations with your database is directly from within the App Service container.
You may check this tutorial sample application:
Tutorial: Build a PHP (Laravel) and MySQL Flexible Server app on Azure App Service
As a side note, these commands or scripts are executed after the built-in Docker container is started, but before your application code is started.
For more info, see: