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

Unable to Consume Luet Packages From Private Registry Due to Authentication Error #354

Open
mokarage opened this issue Mar 27, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@mokarage
Copy link

Luet version:
0.32.5
CPU architecture, OS, and Version:
Debian 4.19.249-2 x86_64 GNU/Linux
Describe the bug
I'm trying to consume (install) a package which I successfully built and pushed to my private registry. I'm getting the following error while I use the command luet install --config repositories.yaml category/package:

failed downloading image my.private.registry.tld/path/to/packages:repository.yaml: GET https://my.private.registry.tld/v2/path/to/packages/manifests/repository.yaml: UNAUTHORIZED: authentication required; [map[Action:pull Class: Name:path/to/packages Type:repository]]

Here is my repositories.yaml configuration:

repositories:
  - name: "test"
    type: "docker"
    priority: 1
    enable: true
    urls:
       - "my.private.registry.tld/path/to/packages"

To Reproduce

  1. Prepare a private registry with htpasswd authentication
  2. Build a package (luet build category/package)
  3. Create repo (luet create-repo --name "test" --type docker --output my.private.registry.tld/path/to/packages --push-images)
  4. Try to install the package (luet install --config repositories.yaml category/package)
  5. The error appears

Expected behavior

Successfully install package from private registry

Logs

  DEBUG   (config.go:#204:github.com/mudler/luet/cmd/util.initContext)  System rootfs: /
  DEBUG   (config.go:#205:github.com/mudler/luet/cmd/util.initContext)  Colors true
  DEBUG   (config.go:#206:github.com/mudler/luet/cmd/util.initContext)  Logging level info
  DEBUG   (config.go:#207:github.com/mudler/luet/cmd/util.initContext)  Debug mode true
 INFO  Luet 0.32.5-gd5d21653d7313ff396c0511af402834c89974ee3 2022-06-07
 INFO  Copyright (C) 2019-2022 Ettore Di Giacinto
       This program comes with ABSOLUTELY NO WARRANTY.
       This is free software, and you are welcome to redistribute it under certain conditions.
       For documentation, visit https://luet.io.
  DEBUG   (install.go:#72:github.com/mudler/luet/cmd.glob..func10)  Solver type:  rate: 0.700000, discount: 1.000000, attempts: 9000, initialobserved: 999999
 INFO   :::> Install
  DEBUG   (repository.go:#895:github.com/mudler/luet/pkg/installer.(*LuetSystemRepository).Sync)  Sync of the repository test in progress...
 INFO   Downloading my.private.registry.tld/path/to/packages:repository.yaml
 WARNING  failed downloading image my.private.registry.tld/path/to/packages:repository.yaml: GET https://my.private.registry.tld/v2/path/to/packages/manifests/repository.yaml: UNAUTHORIZED: authentication required; [map[Action:pull Class: Name:path/to/packages Type:repository]]`
ERROR    Error: Failed matching solutions against repository for category/package where are definitions coming from?!

Additional context

@mokarage mokarage added the bug Something isn't working label Mar 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants