Unknown manifest API version: cluster.gravitational.io/v1beta1

I’m trying to use the ImageSet object to pull in external images to build a new Cluster Image but it keeps throwing.

[ERROR]: could not parse the application manifest:
unknown manifest API version: cluster.gravitational.io/v1beta1

I’m trying the simplest case that I thought would work.
My manifest app.yaml is:

$ tele build app.yaml
apiVersion: cluster.gravitational.io/v1beta1
kind: ImageSet
metadata:
  name: extra-images
spec:
  images:
    - image: nginx:1.11.0
    - image: quay.io/bitnami/redis:5.0

My version should be correct as well:

$ tele version
Edition:	open-source
Version:	7.0.16
Git Commit:	87cfb76878f22fe663a3b20697c15adface3fda8
Helm Version:	v2.15

Hi @markh, welcome to the community!

The app.yaml file should contain the cluster image manifest, not the ImageSet resource. Take a look at the Image Manifest section in our docs, in particular the sample manifest. The manifest file describes your cluster image metadata and allows to tweak various aspects of the installation.

Now, the ImageSet resource as described in Vendoring you can treat as another Kubernetes resource and just drop it among your application’s other Kubernetes YAML spec files.

For example, your cluster image source layout on disk may look like this:

/home/markh/my-cluster/
  - app.yaml       <-- cluster image manifest file
  - imageset.yaml  <-- ImageSet spec
  - resources.yaml <-- other K8s resource specs

This way when you do tele build /home/markh/my-cluster/app.yaml, it will discover Docker image references from all your resources, incl. ones from the image set, and vendor them in the tarball.

Hope this helps,
Roman

Hi @r0mant thanks for answering. Does the app.yaml have to reference the imageset object? I tried including using imageset.yaml (an example below)

apiVersion: cluster.gravitational.io/v1beta1
kind: ImageSet
metadata:
  name: extra-images
spec:
  images:
    - image: external-repo/extra-image:0.01

When the cluster image source is as you suggested above (app.yaml, imageset.yaml, resources.yaml) it builds with no errors but the image is not present when I run

sudo gravity exec docker images