Kong / Kong/kubernetes-testing-framework

Loading image into cluster fails if the image is not available locally: consider falling back to pulling the image

Open
#659 2 comments 0 reactions 0 assignees View on GitHub
area/feature
Dominant language
Go
Stars
44
Forks
11
PR merge metrics
No merged PRs in 30d

Description

### Is there an existing issue for this?

- [X] I have searched the existing issues

### Problem Statement

Currently when the requested image is not available locally, kind (the only implementation that we support) will return an error:

```
ERROR: image: "" not present locally
```

which might be a problem in e.g. complicated CI systems where multiple images are to be used as overrides in CI workflows and a single flag is used for that purpose in order to load the images into a cluster, where 1 image might be locally built and requires loading whereas others are available in external container image registries and do not require loading.

This creates a problem for maintainers of such workflows.

### Proposed Solution

- Implement a fallback mechanism where, whenever an error indicating that an image that was requested in not available locally, we fall back to trying to pull it from an external registry this way being more resilient to errors which should not be considered fatal.

### Additional information

_No response_

### Acceptance Criteria

- [ ] As a user I can rely on KTF to fall back to pulling an image from an external registry if it's not available locally and only then report a failure about a missing image.

Contributor guide

Open the contributing guide

Research direction

Start at the kind image-loading path that reports an image as not present locally. Trace how requested images are loaded into the cluster and how missing-image errors are surfaced. Done means unavailable local images are pulled from an external registry before failure is reported, with the acceptance scenario covered by tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, go, kubernetes
Domain
infrastructure, testing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.