Issue #59 closed: Bug: Deployment sets specific commit SHA instead of HEAD
Description
When deploying an application via the laravel-coolify package, it sets a specific git_commit_sha on the application instead of allowing Coolify to deploy HEAD/latest.
This causes subsequent deployments (including webhook-triggered deploys and manual deploys) to keep deploying the same old commit, even when new commits are pushed to the branch.
Steps to Reproduce
- Use laravel-coolify to deploy an application
- Push new commits to the repository
- Trigger a new deployment (webhook or manual)
- Observe that Coolify deploys the old commit SHA instead of the latest
Expected Behavior
Deployments should pull the latest commit from the configured branch (HEAD), not a pinned commit SHA.
Actual Behavior
The git_commit_sha field on the application gets set to a specific commit, causing all future deploys to use that commit regardless of new pushes.
Suggested Fix
When creating/updating applications or triggering deployments, don't set git_commit_sha unless explicitly requested. Let Coolify handle fetching the latest from the branch.