400 Bad Request when pushing Docker image to registry.fly.io

I have a C# ASP.NET Core backend with a React frontend that I deploy using a single Docker image on fly.io using registry.fly.io . I’ve already deployed my app in the past many times without issue and the app works great. Yesterday, I tried to push a newly-built image with some code changes to registry.fly.io , but I got this error: “unknown: unexpected status from HEAD request to https://registry.fly.io/v2/movie-info-flyio/manifests/dev: 400 Bad Request”. I tried many times today and yesterday to push the Docker image to the registry and I kept getting the same error. And I am making sure to “fly auth docker” beforehand.

It’s strange, because I haven’t changed anything about my app’s infrastructure, including how I build and push to registry.fly.io . Not only that, but the GitHub Actions pipeline I set up to automatically deploy to that same dev environment that also worked previously with no issue has the exact same error, so I know it’s not a local setup problem.

Any ideas what might be causing this error? It doesn’t seem to be a widespread problem or I’d see other threads here about it. But I honestly don’t know why the “docker push” command would be failing in this way.

Hm… Are you perhaps trying to reuse the dev tag? That’s broken in the past, and it’s not completely clear whether Fly.io considers it a supported feature.

(Their examples of --image-label in the official docs suggest that they’re thinking of it as being a fresh tag with each new push.)

The registry is multi-layered, distributed setup these days, so there may be implementation concerns about who still sees the old version of a reused tag, and the like, :thinking:…

(A standard of unique tags, in contrast, creates a monotone system, which is much easier to make distributed.)

Thanks @mayailurus, I think that’s my problem. After changing the tag, it seems to deploy just fine. I’d change the tag each time, but my GitHub Actions expect a certain tag. Maybe there’s a way to fix that in my automated push and deploy setup, but I guess for now I’ll just add a digit to the end of my tag (like “dev2”) and hope this doesn’t crop up very often in future.