You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Symptom:docker push fails with blob unknown / repeated retries when pushing images built
with cache (layers reused from previous builds). All PUT /v2/.../blobs/uploads/... requests return 404.
Cause: The SFTP driver's ensureDir, PutContent, and Move functions checked if the group
folder existed on SFTP before creating directories. Any Stat error — including stale SSH connections
— was treated as "repository not found", returning 404 NAME_INVALID even for repos that already
exist with multiple tags.
Fix: Removed the strict group folder existence checks. The recursive directory creation that
already existed in ensureDir now handles all cases correctly — creating directories as needed
instead of failing.
Fix: SFTP connection pool stale connections
Symptom: After the SFTP server restarts or SSH connections time out, all registry operations
fail until the backend is restarted.
Cause: The SFTP connection pool had no health check or reconnection logic. Broken clients were
returned from the pool indefinitely.
Fix:getClient() now performs a health check (Getwd()) before returning a client. If the
connection is dead, it automatically reconnects and logs [SFTP] Pool: stale connection detected, reconnecting....
Fix: PATCH handler race condition on blob chunk upload
Symptom: Intermittent digest mismatch or incomplete blob data when Docker pushes layers in
parallel across multiple connections.
Cause: The PATCH handler (uploadBlobData) sent the 202 Accepted response before closing
the file writer. If Docker sent the finalizing PUT on a different connection, the file could still be
unflushed.
Fix: File writer is now closed before sending the 202 response, ensuring data is fully
persisted to disk.
Summary
Area
Change
Type
Registry
Fix blob upload 404 on cached docker push
Fix
SFTP
Connection pool health check + auto-reconnect
Fix
Registry
Close chunk file before responding to PATCH
Fix
Upgrade notes
Pull the latest backend image: docker pull troke12/refity-backend:latest
Restart the backend container. No database migration or config changes needed.