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

vm's avatar
Level 2

forge not updating files that was pushed to GitHub

I was under the impression that with "Quick Deploy" in forge turned on, whenever I did a git push origin master , the file in GitHub got updated , and forge has some kind of listener which will automatically update the files on the server so that the server files are in sync with github. However in my case updating server is not happening, when the github files are updated. Am I doing something wrong / OR need to do more / OR is my assumption wrong

Hope someone can help. Thx

0 likes
3 replies
RayRutjes's avatar
Level 4

Normally with the quick deploy option turned on, Forge will automatically pull your changes from GitHub to your server. You can take a look at at what is happening by clicking on "deploy script" an even customize it. I encourage you to take a look at the log of the last deployment by clicking the corresponding button. There you will see if something went wrong. I personnaly stopped using the quick deploy, because sometimes it doesn't fire automatically and you think you missed something in your code, and after 30minutes, you just realize that your code is not in sync with the repo. Now I always check the last deployment log, and also fire the deployment manually.

3 likes
vm's avatar
Level 2

Deployment log had errors. I had done a git reset to go back couple of commits. now the repo was ahead, so i had done a git push -f origin to bring the repo par with master. However this created a problem with the server since now server was ahead by two commits. I ended up sshing into server and reseting git there by two commits. I had to remove some files manually to finally allow forge deploy to work without problems. Next time I will be bit more careful when using force on repo. Now everything is back to normal. Note here, just in case someone else gets into this mess

@RayRutjes,

Automatic pull into server was one of the things I liked about forge. So if that doesn't work properly as you suggest then what else am I getting with forge on a continual basis. Still trying to understand the benefits of forge as I work with it. If you have any insights please advice. I have watched Jeffreys tutorials on it, not sure still what is the value in monthly payment.

RayRutjes's avatar

Forge gives you an easy way to deploy your laravel projects. All what is required by laravel is already configured properly, and will always be. You can deploy projects in minutes. I love to deploy for example a temporary server just to showcase a project to a customer. I boot up the machine in 50s, set up the environment variables in 1 minute, and then I just the deploy the app from my repo. If you don't see the return on investment of forge, maybe you just don't need it yet. Actually I don't use the quick deploy in production, but note that I do use it massively in development, but I now always tend to check my deploy log script. If you need you can also create recipes to do some jobs on your servers, easily install ssl certificates without sshing to the server, and some other fancy stuff. It also enforces you to build your app correctly, with the database migrate stuff, the environment variables etc in mind, and that's a good thing.

2 likes

Please or to participate in this conversation.