prom3theu5 / aspirational-manifests

Handle deployments of .NET Aspire AppHost Projects
MIT License
654 stars 30 forks source link

Unable to publish to a private registry with credentials #257

Open adamtrip opened 2 weeks ago

adamtrip commented 2 weeks ago

I've been trying to generate a project to a private registry but I'm not being able.

 aspirate generate --image-pull-policy Always --non-interactive --include-dashboard --disable-secrets --container-image-tag "1.0.0-qa.8" --container-repository-prefix 'dmstudio' --container-registry ### --private-registry --private-registry-url ### --private-registry-username '###' --private-registry-password '###'

When I run this command I get the following error:

C:\Program Files\dotnet\sdk\8.0.401\Containers\build\Microsoft.NET.Build.Containers.targets(242,5): error CONTAINER1016: Unable to
access the repository 'dmstudio/backend' in the registry '###'. Please confirm your credentials are correct and
that you have access to this repository and registry. [D:\Desenvolvimentos\DMStudio\DMStudio\src\Host\Host.csproj]

if I do a docker login before I'm able to do so but since I'm running this on a github action pipeline, even doing the login before the command, it does not work.

I don't know if I'm missconfiguring something however, if I run the generated publish command and add SDK_CONTAINER_REGISTRY_UNAME and SDK_CONTAINER_REGISTRY_PWORD it publishes it just fine.

Thanks in advance. Any extra info required, just ask :)

CristianWulfing commented 1 day ago

I'm facing the same issue, even if I run git login on the private registry previously.