Skip to content

Cannot use local container images #179

@hawksight

Description

@hawksight

When trying to export CAs from a local docker image, paranoia first seems to attempt to pull the image from docker.
This makes it difficult to test a file that has just been built. A couple of examples:

paranoia export cert-manager.io/local:20230311.deb12u1.0 --output json

A lot of output but the error is easy to see:

error: failed to load image: GET https://cert-manager.io/v2/: unexpected status code 404 Not Found: <!DOCTYPE html><html class="no-js"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width"/><meta name="robots" content="index,follow"/><meta property="og:url" content="https://cert-manager.io"/><meta property="og:type" content="website"/><meta property="og:image" content="https://cert-manager.io/images/og1.png"/><meta property="og:image:alt" content="cert-manager — automated Kubernetes X.509 certificates"/>

I tried again with a different tag:

paranoia export trust-package-local:20230311.deb12u1.0 --output json

Similar error:

error: failed to load image: GET https://index.docker.io/v2/library/trust-package-local/manifests/20230311.deb12u1.0: UNAUTHORIZED: authentication required; [map[Action:pull Class: Name:library/trust-package-local Type:repository]]

A workaround is to just push the image to ttl.sh:

docker tag cert-manager.io/local:20230311.deb12u1.0 ttl.sh/cert-manager-package-debian-dev-peter:2h
paranoia export ttl.sh/cert-manager-package-debian-dev-peter@sha256:6ab5072f567b31d469c580e2c6984cdf7289f12ff03d6415518a69c6bb817e4b --output json

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions