Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build fails when using ContainerBaseImage hosted within Quay with Ceph storage backplane #566

Open
almostjulian opened this issue May 3, 2024 · 3 comments

Comments

@almostjulian
Copy link

I am using a custom base image using the ContainerBaseImage tag in my csproj. The repository the base image is in is using an internal Quay server, backed by a Ceph storage backend. When I try to run dotnet publish I get (from verbose logs):

 Task "CreateNewImage"
         Request URI: GET https://<redacted quay url>
         2b4ba5280a4ceda629c17922b62441b7
         Status code: Found
         Response headers:
         Accept-Ranges: bytes
         Cache-Control: max-age=31536000
         Date: Fri, 03 May 2024 21:56:05 GMT
         Docker-Content-Digest: sha256:f31c5da86bbd82708860371e4d9f23682b4ba5280a4ceda629c17922b62441b7
         Location: http://<redacted ceph backplane url>
         Server: nginx/1.20.1
         X-Frame-Options: DENY

         Response content: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
         <title>Redirecting...</title>
         <h1>Redirecting...</h1>
         <p>You should be redirected automatically to target URL: <a href="http://<redaced ceph url>/">http://<redacted ceph url></a>.  If not click the link.

1:7>C:\Program Files\dotnet\sdk\8.0.300-preview.24203.14\Containers\build\Microsoft.NET.Build.Containers.targets(219,5): err
       or : ContainerHttpException: Containerize: error CONTAINER004: CONTAINER1014: Manifest pull failed. [<redacted project name>]
       C:\Program Files\dotnet\sdk\8.0.300-preview.24203.14\Containers\build\Microsoft.NET.Build.Containers.targets(219,5): err
       or : URI: https://<redacted quay url> [<redacted project name>]
       C:\Program Files\dotnet\sdk\8.0.300-preview.24203.14\Containers\build\Microsoft.NET.Build.Containers.targets(219,5): err
       or :  [<redacted project name>]
       Done executing task "CreateNewImage" -- FAILED.

Is the httpclient being used to fetch this stuff not configured to follow redirects?

@tmds
Copy link
Member

tmds commented May 6, 2024

cc @baronfel

Is the httpclient being used to fetch this stuff not configured to follow redirects?

I would expect it to, but it's strange we're seeing the the Redirect response being printed in the log.

8.0.300-preview.24203.14

@almostjulian does it behave exactly the same if you use the 8.0.104 SDK?

Can you also try if it makes a difference if you pass your credentials through the envvars (SDK_CONTAINER_REGISTRY_UNAME and SDK_CONTAINER_REGISTRY_PWORD)?

@almostjulian
Copy link
Author

@almostjulian does it behave exactly the same if you use the 8.0.104 SDK?

Can you also try if it makes a difference if you pass your credentials through the envvars (SDK_CONTAINER_REGISTRY_UNAME and SDK_CONTAINER_REGISTRY_PWORD)?

Yes, same behavior in 8.0.104. Envvars do not make a difference.

@almostjulian
Copy link
Author

I think the issue is that the Ceph backend is http and I don't think https -> http autoredirect is allowed. I'll see if that's a config change we can make on our end.

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

No branches or pull requests

2 participants