Jxadro
Jxadro

Reputation: 1637

knative 0.4 Serving - Revisions name

Is it possible to set a revision name?

When I create a service it create a configuration and a revision, but the revision name has a "random" suffix that makes it difficult to track the revision order.

Upvotes: 0

Views: 289

Answers (1)

Matthew P
Matthew P

Reputation: 735

Currently Kubernetes generates a random string that Knative uses and hence there is no order. It is possible to create your own revision names but you have to make sure that each revision name is unique (i.e. you need to change my-next-revision):

apiVersion: serving.knative.dev/v1alpha1
kind: Service
metadata:
  name: my-app
  namespace: default
spec:
  release:
    revisions: [my-next-revision]  # Reference the next Revision
    configuration:
      revisionTemplate:
        metadata:
          name: my-next-revision  # Name for next Revision (must change whenever revisionTemplate changes)
        spec:
          ...

A member of the Knative team has said they are considering a 'v1beta1 API proposal is to allow users to "bring your own revision name".'

Full details & all qudos for this information can be found from Matthew Moore in this Google Groups Discussion

Upvotes: 0

Related Questions