feat: Container image polling#169
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds container image polling so agents can periodically compare deployed compose service images with registry digests, pull updated images, and redeploy affected applications. It extends the hub, agent, protobuf protocol, persistence model, and UI settings needed to configure polling per application.
Changes:
- Adds image polling settings to applications, migrations, API DTOs, and frontend forms/translations.
- Adds hub/agent WebSocket messages for polling settings and pull-image results.
- Implements agent-side image polling, digest comparison, image pulling, redeploy logic, and related tests.
Reviewed changes
Copilot reviewed 27 out of 27 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
frontend/src/lib/applications.ts |
Adds image polling fields to application request/response types. |
frontend/src/components/dialogs/upsert-application.tsx |
Adds UI controls and validation for polling settings. |
frontend/messages/en.json |
Adds English polling UI strings. |
frontend/messages/de.json |
Adds German polling UI strings. |
backend/internal/proto/messages.proto |
Adds polling settings/request/result protocol messages. |
backend/internal/hub/websocket/image_poll.go |
Handles image polling results from agents. |
backend/internal/hub/websocket/image_poll_test.go |
Tests image polling result handling. |
backend/internal/hub/websocket/hub.go |
Adds DefaultHub and agent settings sending. |
backend/internal/hub/websocket/hub_test.go |
Tests sending agent settings. |
backend/internal/hub/websocket/handler.go |
Sends settings on connect and routes polling results. |
backend/internal/hub/websocket/handler_test.go |
Tests settings delivery on WebSocket connect. |
backend/internal/hub/routes/applications.go |
Persists polling settings and pushes updates to agents. |
backend/internal/hub/routes/applications_test.go |
Updates route tests for polling settings behavior. |
backend/internal/hub/models/applications.go |
Adds polling fields to the application model. |
backend/internal/hub/handlers.go |
Registers the default WebSocket hub. |
backend/internal/hub/db/migrations/000017_add_application_image_poll.up.sql |
Adds polling columns to applications. |
backend/internal/hub/db/migrations/000017_add_application_image_poll.down.sql |
Drops polling columns on rollback. |
backend/internal/agent/websocket.go |
Applies polling settings and handles pull-image requests. |
backend/internal/agent/websocket_test.go |
Tests new agent WebSocket polling message handling. |
backend/internal/agent/docker/images.go |
Implements digest checks, image pulling, redeploy, and cleanup. |
backend/internal/agent/docker/images_test.go |
Tests image polling Docker logic. |
backend/internal/agent/docker/image_poller.go |
Adds per-application polling scheduler. |
backend/internal/agent/docker/image_poller_test.go |
Tests poller lifecycle and result reporting. |
backend/internal/agent/docker/deploy.go |
Normalizes compose project paths and adds OrcaCD labels. |
backend/internal/agent/docker/deploy_test.go |
Tests project name normalization and deploy errors. |
backend/internal/agent/agent.go |
Wires the poller into agent runtime and reconnect handling. |
backend/internal/agent/agent_config_test.go |
Tests sender reference behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
alex289
approved these changes
May 30, 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.
Type of change
Description
Webhook trigger to be added in another PR.
I would also vote for creating a settings page instead of a modal for applications in the future, as the modal is already too complex.