Skip to content

Conversation

andrian-sevastyanov
Copy link
Collaborator

Attempt to pull images from repo.blackduck.com by default before trying Docker HUB.

A new property --inspector.repository.preferred.registry now defaults to repo.blackduck.com/containers/.
If set, Docker Inspector will first try to pull the images required for running from this registry.
If this is set to an empty string, Docker Inspector will proceed directly to Docker HUB.

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces a preferred registry fallback mechanism for Docker Inspector images. The system will now attempt to pull images from repo.blackduck.com/containers/ by default before falling back to Docker HUB.

  • Adds a new configuration property inspector.repository.preferred.registry with default value repo.blackduck.com/containers/
  • Implements fallback logic that tries the preferred registry first, then Docker HUB if preferred registry fails
  • Adds state tracking to avoid repeated attempts to unreachable preferred repositories

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
Config.java Adds new configuration property for preferred registry with getter method
ImageInspectorClientStartServices.java Implements preferred registry fallback logic with new PullResult class
IiClientContainersStartedAsNeededTest.java Updates test to mock the new configuration property

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

…tor/httpclient/ImageInspectorClientStartServices.java

Co-authored-by: Copilot <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants