Skip to content

[BUG] Cup does not ignore registries nor exclude images, throws error at startup #145

@GiamBoscaro

Description

@GiamBoscaro

Describe the bug
I am trying to ignore my own private images so I can avoid adding the GITHUB_TOKEN to the config. But anything I tried, CUP fails to startup because it tries to reach for my private repos.

To Reproduce
Use the config provided and run cup.

Expected behavior
Should ignore the registries listed in registries with ignore: true or/and images in the exclude list.

System info (please complete the following information):

  • OS: Synology DSM 7.2
  • Docker daemon version: 24.0.2
  • Cup version: 3.4.3

Additional context

cup.json

{
  "refresh_interval": "0 0 */6 * * *",
  "registries": {
    "ghcr.io/giamboscaro": {
      "ignore": true
    }
  },
  "images": {
    "exclude": ["ghcr.io/giamboscaro"],
    "extra": [
      "ghcr.io/sergi0g/cup:latest",
      "glanceapp/glance:latest",
      "postgres:16-trixie",
      "robiningelbrecht/strava-statistics:latest",
      "traefik:latest",
      "linuxserver/transmission:latest"
    ]
  }
}

Logs:

WARN GET https://ghcr.io/token?&service=ghcr.io&scope=repository:user/image:pull&scope=repository:giamboscaro/..................................
Unauthorized! Please configure authentication for this registry or if you have already done so, please make sure it is correct.
ERROR GET https://ghcr.io/token?&service=ghcr.io&scope=repository:user/image:pull&scope=repository:giamboscaro/..................................
Request failed!

Test docker run to quickly deploy the container for testing:

docker run --rm --name cup-test -v /tmp/docker-test/config.json:/config/cup.json:ro -v /var/run/docker.sock:/var/run/docker.sock:ro ghcr.io/sergi0g/cup:latest -c /config/cup.json serve

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions