Project

Profile

Help

Story #1908

closed

As a user, I can rely on crane to check the destination target before redirecting

Added by jluza almost 8 years ago. Updated about 5 years ago.

Status:
CLOSED - WONTFIX
Priority:
Normal
Assignee:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Platform Release:
Target Release - Crane:
master
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

Following situation

repo1 - layers: [a,b,c], redirect url: https://foo.bar/repo1/layers/
repo2 - layers: [a,b,d], redirect url: https://foo.bar/repo2/layers/

let's assume https://foo.bar/repo2/layers/ is unreachable/broken for some reason. When user does
docker pull repo1
it fails because repo1 and repo2 share layer a so crane redirects GET /v1/images/088b4505aa3adc3d35e79c031fa126b403200f02f51920fbd9b7c503e87c7a2c/layer to
https://foo.bar/repo2/layers/ which is not reachable.

better solution: crane will http HEAD destination first and redirect to the destination only if it's reachable, otherwise will choose next destination from the list.

Also available in: Atom PDF