[Feat] Check for updates automatically#1116
Merged
RichardAnderson merged 2 commits intoMay 23, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds an automated daily “check for package updates” workflow across all READY servers and updates the SSH parsing/counting logic used to compute the number of available OS package upgrades.
Changes:
- Add
servers:check-updatesArtisan command plus a queued job (CheckForUpdatesJob) to run per-server update checks and broadcastserver.updated. - Schedule the new command to run daily at 02:00.
- Refine available-updates counting by adjusting the SSH script output and simplifying the parsing logic in
OS::availableUpdates().
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| resources/views/ssh/os/available-updates.blade.php | Adjusts the apt command pipeline used to count upgradable packages. |
| app/SSH/OS/OS.php | Updates parsing/counting logic for “Available updates:” output. |
| app/Jobs/Server/CheckForUpdatesJob.php | Introduces a queued job that runs update checks and broadcasts server updates. |
| app/Console/Kernel.php | Schedules the new servers:check-updates command daily. |
| app/Console/Commands/CheckServerUpdatesCommand.php | Adds a command that dispatches per-server update-check jobs for READY servers. |
saeedvaziry
approved these changes
May 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new scheduled process to check for package updates on all servers and improves the accuracy of update counting. The main changes include adding a new Artisan command and job for checking updates, scheduling this check to run daily, and refining the logic for determining the number of available updates.
OS.phpto accurately count available updates by removing an unnecessary subtraction, ensuring the number does not go below zero.available-updates.blade.phpto filter out the header line and suppress error output, providing a more accurate count of upgradable packages.