Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

martinszeltins's avatar

Giving users an update option from the app

I know that I can deploy a newer version of the app by git pull and then running the artisan migrate commands. But how could I give the user a button that they can click (from the frontend) and the newest version will be deployed automatically?

How is this one? Has anyone done this before?

Thanks!

0 likes
3 replies
aurawindsurfing's avatar

Hey @martinzeltin

What you could do is allow them to call a method in controller which in turn will execute something like that:

shell_exec('git pull origin/master && artisan migrate');
aurawindsurfing's avatar

This is probably the better advice, but does not answer the question :-)

Please or to participate in this conversation.