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

gork4life's avatar

Cannot get site to update on server through forge.

I've created a server through forge that I'm successful got running. Thing is when I make changes on my local and commit and push it to the repo, it doesn't update with changes. Whether I use quick deploy or manual my changes don't get updated on the the server. Has anyone ever experienced this.

0 likes
1 reply
LaryAI's avatar
Level 58

Certainly! This is a common issue when deploying with Laravel Forge. Here are some steps and checks to help you resolve the problem:

  1. Check the Deploy Script
    Make sure your site's deploy script (found in the Forge dashboard under "Sites" > "Deploy Script") is correctly pulling the latest changes from your repository. A typical deploy script starts with:

    cd /home/forge/your-domain.com
    git pull origin main
    

    Replace main with your branch name if it's different.

  2. Repository Connection
    Ensure that Forge has access to your repository. If you recently changed repository permissions or SSH keys, Forge might not be able to pull the latest changes. You can test this by SSHing into your server and running:

    cd /home/forge/your-domain.com
    git pull origin main
    

    If you see any errors, resolve them (it could be SSH key issues or permission problems).

  3. Check for Local Changes on Server
    Sometimes, if files on the server have been modified manually, git pull can fail silently. SSH into your server and check for unstaged changes:

    cd /home/forge/your-domain.com
    git status
    

    If you see modified files, you may need to commit, stash, or reset them.

  4. Quick Deploy/Manual Deploy
    Make sure you are triggering the correct deploy script. In Forge, "Quick Deploy" should run the same deploy script as a manual deploy. Double-check that the script is saved and up-to-date.

  5. Check Forge Deploy Logs
    In the Forge dashboard, check the "Deployments" tab for your site. Review the logs for any errors or clues as to why the deployment isn't updating your code.

  6. Clear Caches
    If your code is updating but changes aren't reflected, you may need to clear Laravel's cache:

    php artisan cache:clear
    php artisan config:clear
    php artisan view:clear
    php artisan route:clear
    
  7. Permissions
    Ensure the forge user (or the user running the deploy) has the correct permissions to write to the project directory.


Summary:

  • Double-check your deploy script and repository access.
  • SSH into your server and try a manual git pull.
  • Check for local changes or permission issues.
  • Review Forge's deployment logs for errors.

If you follow these steps, you should be able to identify why your site isn't updating with the latest changes from your repository. If you encounter a specific error during any of these steps, feel free to share it for more targeted help!

Please or to participate in this conversation.