hi-ko
(Heiko Robert)
January 19, 2025, 1:41pm
1
I’m trying to run immich’s postgres vector variant as docker image.
Image is listed as https://hub.docker.com/r/tensorchord/pgvecto-rs
Other images from docker.io load as expected (e.g. incus init docker:apache/tika:latest tika
), but when I try to init the tensorchord/pgvecto-rs
image I get:
incus init docker:tensorchord/pgvecto-rs immich-postgres
Creating immich-postgres
Error: Failed instance creation: Failed getting remote image info: Image not found
Has anyone a hint/idea what the issue could be?
Janm84
January 19, 2025, 2:46pm
2
I had a similar Error thease days with my private registry. But in my case i couldn’t pull anything from the registry.
It was related to my self signed certificates.
But in your case that seams to be something different maybe.
Incus remote / prvate docker-registry - Image not found
htcosta
(Helder Costa)
January 19, 2025, 8:05pm
3
Aren’t you forgetting the tag/version/release field? eg:
tensorchord/pgvecto-rs:pg15-v0.4.0-rootless
hi-ko
(Heiko Robert)
January 20, 2025, 7:34am
4
thanks @htcosta ,
I tried the digest notation and latest
alias from immich-app’s docker-compose.yml which does not seem to work.
Using the version from that image instead now works as expected:
incus init docker:tensorchord/pgvecto-rs:pg14-v0.2.0 immich-postgres
hi-ko
(Heiko Robert)
January 20, 2025, 7:55am
5
would be nice to also have support for pulling docker images by digest or hash.
Once I got the image by version I see the expected hash
volatile.base_image: 90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
but trying to copy the image from docker.io by hash fails:
incus copy docker:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0 local:
Error: The remote isn't a private server
stgraber
(Stéphane Graber)
January 20, 2025, 3:52pm
6
As far as I could tell (at least from what Skopeo offers), there’s no way to retrieve an image directly by hash from a registry.
candlerb
(Brian Candler)
January 21, 2025, 12:34pm
7
I was fairly sure you could do that with docker - that is, use a hash instead of a tag name.
From the OCI distribution spec :
To pull a manifest, perform a GET
request to a URL in the following form: /v2/<name>/manifests/<reference>
<name>
refers to the namespace of the repository. <reference>
MUST be either (a) the digest of the manifest or (b) a tag name.
stgraber
(Stéphane Graber)
January 21, 2025, 12:41pm
8
You can use the digest but only in combination with the image name, not on its own.
Stéphane
candlerb
(Brian Candler)
January 21, 2025, 1:13pm
9
Ah right. Perhaps it would be helpful then to remember it somewhere? e.g.
volatile.base_image: tensorchord/pgvecto-rs:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
(if it’s not already recorded somewhere else - I don’t have a non-LTS to test on at the moment)
stgraber
(Stéphane Graber)
January 21, 2025, 3:00pm
10
The needed information is already captured:
stgraber@castiana:~$ incus launch oci-docker:nginx nginx
Launching nginx
stgraber@castiana:~$ incus config show nginx
architecture: x86_64
config:
environment.DYNPKG_RELEASE: 1~bookworm
environment.HOME: /root
environment.NGINX_VERSION: 1.27.3
environment.NJS_RELEASE: 1~bookworm
environment.NJS_VERSION: 0.8.7
environment.PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
environment.PKG_RELEASE: 1~bookworm
environment.TERM: xterm
image.architecture: x86_64
image.description: docker.io/library/nginx (OCI)
image.id: nginx
image.type: oci
volatile.base_image: 0a399eb16751829e1af26fea27b20c3ec28d7ab1fb72182879dcae1cca21206a
volatile.cloud-init.instance-id: 99816701-365d-47a5-b578-f17efcbf83d8
volatile.container.oci: "true"
volatile.eth0.host_name: veth340d3fd6
volatile.eth0.hwaddr: 00:16:3e:14:42:10
volatile.idmap.base: "0"
volatile.idmap.current: '[{"Isuid":true,"Isgid":false,"Hostid":1000000,"Nsid":0,"Maprange":1000000000},{"Isuid":false,"Isgid":true,"Hostid":1000000,"Nsid":0,"Maprange":1000000000}]'
volatile.idmap.next: '[{"Isuid":true,"Isgid":false,"Hostid":1000000,"Nsid":0,"Maprange":1000000000},{"Isuid":false,"Isgid":true,"Hostid":1000000,"Nsid":0,"Maprange":1000000000}]'
volatile.last_state.idmap: '[]'
volatile.last_state.power: RUNNING
volatile.uuid: f44f12cd-ceef-4359-a2be-8b0aa5c298e1
volatile.uuid.generation: f44f12cd-ceef-4359-a2be-8b0aa5c298e1
devices: {}
ephemeral: false
profiles:
- default
stateful: false
description: ""
1 Like
hi-ko
(Heiko Robert)
January 21, 2025, 3:19pm
11
That’s true. I guess image.id and volatile.base_image is all we need to map.
Question is how to translate the / notation from the docker compose file into a incus command if there is no option to use the hash as a filter for the images with a given id.
hi-ko
(Heiko Robert)
January 21, 2025, 3:22pm
12
Currently I’m more struggling getting some images to work not only having environment variables to be added in the environment. I will create another topic for that not to mismatch things …