Currentl kn service export export services, but does not cleanup everything. Some default values are still contained like in:
apiVersion: client.knative.dev/v1alpha1
kind: Export
metadata:
creationTimestamp: null
spec:
revisions: null
service:
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
creationTimestamp: null
name: demo
spec:
template:
metadata:
annotations:
client.knative.dev/user-image: rhuss/random:1.0
creationTimestamp: null
spec:
containerConcurrency: 0
containers:
- env:
- name: foo
value: bar
- name: blub
value: bla
image: index.docker.io/rhuss/random@sha256:946b7ca7f880ca38e4930cd625d4533616bba75f5fafde132cc3b7e7ae3a18b5
name: user-container
readinessProbe:
successThreshold: 1
tcpSocket:
port: 0
resources: {}
enableServiceLinks: false
timeoutSeconds: 300
status: {}
creationTimestamp should be removed
- Remove
status: section
- Readiness Probe can be removed, too, if its the default (tricky)
user-container name can be removed
revisions: section can be removed
For the "replay" format:
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
creationTimestamp: null
name: demo
spec:
template:
metadata:
annotations:
client.knative.dev/user-image: rhuss/random:1.0
creationTimestamp: null
spec:
containerConcurrency: 0
containers:
- env:
- name: foo
value: bar
- name: blub
value: bla
image: index.docker.io/rhuss/random@sha256:946b7ca7f880ca38e4930cd625d4533616bba75f5fafde132cc3b7e7ae3a18b5
name: user-container
readinessProbe:
successThreshold: 1
tcpSocket:
port: 0
resources: {}
enableServiceLinks: false
timeoutSeconds: 300
status: {}
As above, plus
enableServiceLinks and timeoutSeconds could be removed if they reflect the default. Again, this is tricky as how should we know when this is default or not ?
- the empty
resources: can be removed
Currentl
kn service exportexport services, but does not cleanup everything. Some default values are still contained like in:creationTimestampshould be removedstatus:sectionuser-containername can be removedrevisions:section can be removedFor the "replay" format:
As above, plus
enableServiceLinksandtimeoutSecondscould be removed if they reflect the default. Again, this is tricky as how should we know when this is default or not ?resources:can be removed