appc / spec

App Container Specification and Tooling (archived, see https://github.com/rkt/rkt/issues/4024)
Apache License 2.0
1.26k stars 146 forks source link

"actool discover" accepts non existing images #592

Open alban opened 8 years ago

alban commented 8 years ago

The image "coreos.com/etcd-etcd-etcd-etcd:v2.0.10" is not supposed to exist, but actool discover finds it anyway by truncating the name:

$ actool discover coreos.com/etcd-etcd-etcd-etcd:v2.0.10
discover walk: prefix: coreos.com/etcd-etcd-etcd-etcd error: expected a 200 OK got 403
ACI: https://github.com/coreos/etcd/releases/download/v2.0.10/etcd-v2.0.10-linux-amd64.aci, ASC: https://github.com/coreos/etcd/releases/download/v2.0.10/etcd-v2.0.10-linux-amd64.aci.asc
Keys: https://coreos.com/dist/pubkeys/aci-pubkeys.gpg,https://coreos.com/dist/pubkeys/app-signing-pubkey.gpg

As a consequence, rkt can run it:

$ sudo rkt run --insecure-options=image coreos.com/etcd-etcd-etcd-etcd:v2.0.10
image: using image from local store for image name coreos.com/rkt/stage1-coreos:1.3.0
image: searching for app image coreos.com/etcd-etcd-etcd-etcd
image: remote fetching from URL "https://github.com/coreos/etcd/releases/download/v2.0.10/etcd-v2.0.10-linux-amd64.aci"
Downloading ACI: [=============================================] 3.79 MB/3.79 MB
networking: loading networks from /etc/rkt/net.d
networking: overriding "default" network with long.conf
networking: loading network default with type ptp
[334210.278023] etcd[4]: 2016/04/07 13:46:21 etcd: no data-dir provided, using default data-dir ./default.etcd
jonboulle commented 8 years ago

@alban what happens without --insecure-options=image?

alban commented 8 years ago

@jonboulle it gives the following error:

Downloading ACI: [=============================================] 3.79 MB/3.79 MB
run: 
  └─error when reading the app name: "coreos.com/etcd-etcd-etcd-etcd" expected but "coreos.com/etcd" found